1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

Fuzzy rework, added more defence and gather army routines

This commit is contained in:
Andrii Danylchenko
2023-06-04 16:02:02 +03:00
parent b1ca663eb6
commit b19ac01bf9
28 changed files with 710 additions and 195 deletions

View File

@@ -879,7 +879,7 @@ void AINodeStorage::setHeroes(std::map<const CGHeroInstance *, HeroRole> heroes)
for(auto & hero : heroes)
{
// do not allow our own heroes in garrison to act on map
if(hero.first->getOwner() == ai->playerID && hero.first->inTownGarrison)
if(hero.first->getOwner() == ai->playerID && hero.first->inTownGarrison && ai->isHeroLocked(hero.first))
continue;
uint64_t mask = FirstActorMask << actors.size();