Beispiel #1
0
 public int getUnitLevel(UnitType unit) {
   for (Research research : researchs) {
     ResearchType researchType = research.getType();
     if (researchType.getId() == ResearchType.UNITTYPE && researchType.getUnitType() == unit)
       return research.getLevel();
   }
   return 0;
 }
Beispiel #2
0
 public int getProductionLevel(int productionImprovementId) {
   for (Research research : researchs) {
     ResearchType researchType = research.getType();
     if (researchType.getId() == ResearchType.PRODUCTION
         && researchType.getProductionImprovementId() == productionImprovementId)
       return research.getLevel();
   }
   return 0;
 }