1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-08-13 19:54:17 +02:00

Merge pull request #1595 from vcmi/vkai-hack-to-workaround-freezes

VCAI: hard limit on iterations per turn
This commit is contained in:
Ivan Savenko
2023-03-31 18:15:58 +03:00
committed by GitHub

View File

@@ -863,7 +863,7 @@ void VCAI::mainLoop()
invalidPathHeroes.clear();
while (basicGoals.size())
for (int pass = 0; pass< 30 && basicGoals.size(); pass++)
{
vstd::removeDuplicates(basicGoals); //TODO: container which does this automagically without has would be nice
goalsToAdd.clear();