1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-29 23:07:48 +02:00

Converted pathfinder enum's to enum class

This commit is contained in:
Ivan Savenko
2023-06-21 15:38:57 +03:00
parent f78470a301
commit ebc7a82c2e
24 changed files with 162 additions and 161 deletions

View File

@@ -1196,11 +1196,11 @@ bool AIGateway::moveHeroToTile(int3 dst, HeroPtr h)
//return cb->getTile(coord,false)->topVisitableObj(ignoreHero);
};
auto isTeleportAction = [&](CGPathNode::ENodeAction action) -> bool
auto isTeleportAction = [&](EPathNodeAction action) -> bool
{
if(action != CGPathNode::TELEPORT_NORMAL && action != CGPathNode::TELEPORT_BLOCKING_VISIT)
if(action != EPathNodeAction::TELEPORT_NORMAL && action != EPathNodeAction::TELEPORT_BLOCKING_VISIT)
{
if(action != CGPathNode::TELEPORT_BATTLE)
if(action != EPathNodeAction::TELEPORT_BATTLE)
{
return false;
}
@@ -1311,7 +1311,7 @@ bool AIGateway::moveHeroToTile(int3 dst, HeroPtr h)
doChannelProbing();
}
if(path.nodes[0].action == CGPathNode::BLOCKING_VISIT || path.nodes[0].action == CGPathNode::BATTLE)
if(path.nodes[0].action == EPathNodeAction::BLOCKING_VISIT || path.nodes[0].action == EPathNodeAction::BATTLE)
{
// when we take resource we do not reach its position. We even might not move
// also guarded town is not get visited automatically after capturing