diff --git a/AI/Nullkiller/Pathfinding/AINodeStorage.cpp b/AI/Nullkiller/Pathfinding/AINodeStorage.cpp index 608e94d4f..44159791c 100644 --- a/AI/Nullkiller/Pathfinding/AINodeStorage.cpp +++ b/AI/Nullkiller/Pathfinding/AINodeStorage.cpp @@ -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(pos, tile, fow, player, gs)); if (useFlying)