瀏覽代碼

Fix player not being marked as defeated on losing all heroes and towns

Ivan Savenko 1 年之前
父節點
當前提交
01697e4387
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lib/CPlayerState.h

+ 1 - 1
lib/CPlayerState.h

@@ -104,7 +104,7 @@ public:
 
 
 	bool checkVanquished() const
 	bool checkVanquished() const
 	{
 	{
-		return ownedObjects.empty();
+		return getHeroes().empty() && getTowns().empty();
 	}
 	}
 
 
 	template <typename Handler> void serialize(Handler &h)
 	template <typename Handler> void serialize(Handler &h)