瀏覽代碼

Update BuildingBehavior.cpp

Fixed a warning which, in this case, was actually also a logical error! :o
Xilmi 1 年之前
父節點
當前提交
8cf99616d0
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      AI/Nullkiller/Behaviors/BuildingBehavior.cpp

+ 1 - 1
AI/Nullkiller/Behaviors/BuildingBehavior.cpp

@@ -60,7 +60,7 @@ Goals::TGoalVec BuildingBehavior::decompose(const Nullkiller * ai) const
 		}
 		for (auto& buildingInfo : developmentInfo.toBuild)
 		{
-			if (closestThreat <= 1 && developmentInfo.town->fortLevel() < BuildingID::CASTLE && !buildingInfo.notEnoughRes)
+			if (closestThreat <= 1 && developmentInfo.town->fortLevel() < CGTownInstance::EFortLevel::CASTLE && !buildingInfo.notEnoughRes)
 			{
 				if (buildingInfo.id == BuildingID::FORT || buildingInfo.id == BuildingID::CITADEL || buildingInfo.id == BuildingID::CASTLE)
 					tasks.push_back(sptr(BuildThis(buildingInfo, developmentInfo)));