道具加速问题
parent
81638a0bc6
commit
28ac06a311
|
|
@ -264,10 +264,10 @@ public class TrainingLogic {
|
|||
}
|
||||
STrainBuild trainBuild = STrainBuild.getMap().get(archId);
|
||||
STrainBuildLevel buildLevel = STrainBuildLevel.getPoolMap().get(trainBuild.getLvupCostPool()).get(architecture.getLv());
|
||||
if (buildLevel == null || buildLevel.getCost() == null){
|
||||
if (buildLevel == null || buildLevel.getSpeedUp() == null){
|
||||
throw new ErrorCodeException(ErrorCode.CFG_NULL, "未找到对应等级的建筑!");
|
||||
}
|
||||
Map<Integer, Long> selected = ToolsUtil.selectCostItem(buildLevel.getCost());
|
||||
Map<Integer, Long> selected = ToolsUtil.selectCostItem(buildLevel.getSpeedUp());
|
||||
if (!selected.containsKey(itemId)){
|
||||
throw new ErrorCodeException(ErrorCode.ITEM_NOT_ENOUGH);//物品不足
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue