1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-26 03:52:01 +02:00
This commit is contained in:
Tomasz Zieliński 2022-09-25 08:07:22 +02:00
parent 97a94ce61e
commit fd63cb6109

View File

@ -88,11 +88,11 @@ void AINodeStorage::initialize(const PathfinderOptions & options, const CGameSta
{
for(pos.y = 0; pos.y < sizes.y; ++pos.y)
{
const TerrainTile* tile = &gs->map->getTile(pos);
if (!tile->terType->isPassable())
const TerrainTile & tile = gs->map->getTile(pos);
if (!tile.terType->isPassable())
continue;
if (tile->terType->isWater())
if (tile.terType->isWater())
{
resetTile(pos, ELayer::SAIL, PathfinderUtil::evaluateAccessibility<ELayer::SAIL>(pos, tile, fow, player, gs));
if (useFlying)