1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

CPathfinder: move passability checks into renamed goodForLandSeaTransition

There no need in dedicated function for embark / disembark and other conditions belong there perfectly.
This function is going to check what movements are plain impossible so we don't have to bother check their cost.
This commit is contained in:
ArseniyShestakov
2015-10-12 07:10:33 +03:00
parent ee4305cd6d
commit c6f9cd1e52
2 changed files with 6 additions and 7 deletions

View File

@@ -305,7 +305,7 @@ private:
CGPathNode *getNode(const int3 &coord);
void initializeGraph();
bool goodForLandSeaTransition(); //checks if current move will be between sea<->land. If so, checks it legality (returns false if movement is not possible) and sets useEmbarkCost
bool isMovementPossible(); //checks if current move will be between sea<->land. If so, checks it legality (returns false if movement is not possible) and sets useEmbarkCost
void getNeighbours(const int3 &coord);
void getTeleportExits(bool noTeleportExcludes = false);