mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-28 08:48:48 +02:00
[AI] Teach BattleAI how to use offensive location spells (like fireball)
* AI already can evaluate effect of smart and not smart offensive spells.
This commit is contained in:
parent
3b2a45c8dc
commit
3de47d4df6
@ -567,6 +567,14 @@ std::vector<BattleHex> CBattleAI::getTargetsToConsider(const CSpell * spell, con
|
||||
}
|
||||
}
|
||||
break;
|
||||
case CSpell::LOCATION:
|
||||
{
|
||||
for(int i = 0; i < GameConstants::BFIELD_SIZE; i++)
|
||||
if(BattleHex(i).isAvailable())
|
||||
ret.push_back(i);
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user