Browse Source

CPathfinder: only allow water walking over accessible tiles

ArseniyShestakov 10 years ago
parent
commit
a1290f548b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/CPathfinder.cpp

+ 1 - 1
lib/CPathfinder.cpp

@@ -292,7 +292,7 @@ bool CPathfinder::isMovementToDestPossible()
 			break;
 
 		case EPathfindingLayer::WATER:
-			if(!canMoveBetween(cp->coord, dp->coord) || dp->accessible == CGPathNode::BLOCKED)
+			if(!canMoveBetween(cp->coord, dp->coord) || dp->accessible != CGPathNode::ACCESSIBLE)
 				return false;
 			if(isDestinationGuarded())
 				return false;