浏览代码

VCAI::showGarrisonDialog: don't try to pick army from locked garrison

Arseniy Shestakov 9 年之前
父节点
当前提交
02a45007e7
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      AI/VCAI/VCAI.cpp

+ 3 - 1
AI/VCAI/VCAI.cpp

@@ -697,7 +697,9 @@ void VCAI::showGarrisonDialog(const CArmedInstance *up, const CGHeroInstance *do
 	//you can't request action from action-response thread
 	requestActionASAP([=]()
 	{
-		pickBestCreatures (down, up);
+		if(removableUnits)
+			pickBestCreatures(down, up);
+
 		answerQuery(queryID, 0);
 	});
 }