#include <AIPathfind.h>
Public Member Functions | |
| PathfindLayer () | |
| ~PathfindLayer () | |
| void | reset (void) |
| Bool | init (Bridge *theBridge, PathfindLayerEnum layer) |
| void | allocateCells (const IRegion2D *extent) |
| void | allocateCellsForWallLayer (const IRegion2D *extent, ObjectID *wallPieces, Int numPieces) |
| void | classifyCells () |
| void | classifyWallCells (ObjectID *wallPieces, Int numPieces) |
| Bool | setDestroyed (Bool destroyed) |
| Bool | isUnused (void) |
| Bool | isDestroyed (void) |
| PathfindCell * | getCell (Int x, Int y) |
| Int | getZone (void) |
| void | setZone (Int zone) |
| void | applyZone (void) |
| void | getStartCellIndex (ICoord2D *start) |
| void | getEndCellIndex (ICoord2D *end) |
| ObjectID | getBridgeID (void) |
| Bool | connectsZones (PathfindZoneManager *zm, const LocomotorSet &locomotorSet, Int zone1, Int zone2) |
| Bool | isPointOnWall (ObjectID *wallPieces, Int numPieces, const Coord3D *pt) |
Protected Member Functions | |
| void | classifyLayerMapCell (Int i, Int j, PathfindCell *cell, Bridge *theBridge) |
| void | classifyWallMapCell (Int i, Int j, PathfindCell *cell, ObjectID *wallPieces, Int numPieces) |
This class represents a bridge in the map. This is effectively a sub-rectangle of the big pathfind map.
Definition at line 387 of file AIPathfind.h.
| PathfindLayer::PathfindLayer | ( | ) |
Definition at line 3198 of file AIPathfind.cpp.
| PathfindLayer::~PathfindLayer | ( | ) |
Definition at line 3215 of file AIPathfind.cpp.
| void PathfindLayer::allocateCells | ( | const IRegion2D * | extent | ) |
Allocates the pathfind cells for the bridge layer.
Definition at line 3371 of file AIPathfind.cpp.
| void PathfindLayer::allocateCellsForWallLayer | ( | const IRegion2D * | extent, |
| ObjectID * | wallPieces, | ||
| Int | numPieces ) |
Allocates the pathfind cells for the wall bridge layer.
Definition at line 3410 of file AIPathfind.cpp.
| void PathfindLayer::applyZone | ( | void | ) |
Copies m_zone into the zone for all the member cells.
Definition at line 3626 of file AIPathfind.cpp.
| void PathfindLayer::classifyCells | ( | ) |
Classifies the pathfind cells for the bridge layer.
Definition at line 3499 of file AIPathfind.cpp.
|
protected |
Classify the given map cell as clear, or not, etc.
Definition at line 3671 of file AIPathfind.cpp.
Classifies the pathfind cells for the wall bridge layer.
Definition at line 3550 of file AIPathfind.cpp.
|
protected |
Classify the given map cell as clear, or not, etc.
Definition at line 3784 of file AIPathfind.cpp.
| Bool PathfindLayer::connectsZones | ( | PathfindZoneManager * | zm, |
| const LocomotorSet & | locoSet, | ||
| Int | zone1, | ||
| Int | zone2 ) |
Checks to see if a broken bridge connects 2 zones.
Definition at line 3468 of file AIPathfind.cpp.
| ObjectID PathfindLayer::getBridgeID | ( | void | ) |
Return the bridge's object id.
Definition at line 3641 of file AIPathfind.cpp.
| PathfindCell * PathfindLayer::getCell | ( | Int | x, |
| Int | y ) |
Return the cell at the index location.
Definition at line 3649 of file AIPathfind.cpp.
|
inline |
Definition at line 407 of file AIPathfind.h.
|
inline |
Definition at line 406 of file AIPathfind.h.
|
inline |
Definition at line 403 of file AIPathfind.h.
| Bool PathfindLayer::init | ( | Bridge * | theBridge, |
| PathfindLayerEnum | layer ) |
Draws debug cell info. Sets the bridge & layer number for a layer.
Definition at line 3359 of file AIPathfind.cpp.
|
inline |
Definition at line 401 of file AIPathfind.h.
Definition at line 3752 of file AIPathfind.cpp.
| Bool PathfindLayer::isUnused | ( | void | ) |
Returns true if the layer is avaialble for use.
Definition at line 3255 of file AIPathfind.cpp.
| void PathfindLayer::reset | ( | void | ) |
Returns true if the layer is avaialble for use.
Definition at line 3223 of file AIPathfind.cpp.
Relassifies the pathfind cells for the destroyed bridge layer.
Definition at line 3613 of file AIPathfind.cpp.
|
inline |
Definition at line 404 of file AIPathfind.h.