mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-08 00:39:47 +02:00
Fixed an issue that could cause the AI to skip almost their entire turn
If the best Task is to recruit a hero this now triggers pathfinding again as the newly bought hero may impair other heroe's paths.
This commit is contained in:
parent
71553783e6
commit
eab6de4686
@ -397,7 +397,12 @@ void Nullkiller::makeTurn()
|
||||
if(!executeTask(bestTask))
|
||||
return;
|
||||
|
||||
updateAiState(i, true);
|
||||
bool fastUpdate = true;
|
||||
|
||||
if (bestTask->getHero() != nullptr)
|
||||
fastUpdate = false;
|
||||
|
||||
updateAiState(i, fastUpdate);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user