Package net.traviangui.model

Examples of net.traviangui.model.Troops


                    codLocation = Util.patternExtract( "\\?d=(\\d+)&", domLocations[numNode].toString(), 1)[0];
              }                 
              numNode++;
             
              System.out.println( "* Village=" + codLocation);
              Troops troops = new Troops( village);
//                Util.printTagNodes( domTroopTypes);
//                Util.printTagNodes( domTroopQuantities);
                for( int i=0 ; i < domTroopTypes.length ; i++) {
//                  System.out.printf( "type=%s, quantity=%d\n", domTroopTypes[i].toString(), troopQuantity);

                  String troopType  = Translator.translate( domTroopTypes[i].toString().trim());
                  int troopQuantity = Integer.parseInt( domTroopQuantities[i].toString().trim());
                  TroopUnit tu = new TroopUnit( TroopType.getByName( troopType), troopQuantity);
                  troops.addTroops( tu);
                  System.out.println( " * " + tu);
                }
          }
        }

View Full Code Here

TOP

Related Classes of net.traviangui.model.Troops

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.