示例#1
0
文件: Side.java 项目: Lykos/Waldspiel
 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;
 }
示例#2
0
文件: Side.java 项目: Lykos/Waldspiel
 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;
 }