diff options
Diffstat (limited to 'src/resources/map')
-rw-r--r-- | src/resources/map/map.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/resources/map/map.cpp b/src/resources/map/map.cpp index 39dc4b28f..b2697ddcf 100644 --- a/src/resources/map/map.cpp +++ b/src/resources/map/map.cpp @@ -915,7 +915,9 @@ Path Map::findPath(const int startX, const int startY, // Skip if the tile is on the closed list or is not walkable // unless its the destination tile - // +++ here need check block must depend on player abilities. + // +++ probably here "newTile->blockmask & BlockMask::WALL" + // can be removed. It left here only for protect from + // walk on wall in any case if (newTile->whichList == mOnClosedList || ((newTile->blockmask & blockWalkMask) && !(x == destX && y == destY)) @@ -933,9 +935,8 @@ Path Map::findPath(const int startX, const int startY, const MetaTile *const t2 = &mMetaTiles[curr.x + dx + curWidth]; - // +++ here need check block must depend // on player abilities. - if (((t1->blockmask | t2->blockmask) & BlockMask::WALL)) + if (((t1->blockmask | t2->blockmask) & blockWalkMask)) continue; } |