#include <th_pathfind.h>
|
| | idle_tile_finder (pathfinder *pf) |
| |
| int | guess_distance (path_node *pNode) override |
| | Guess distance to the destination for pNode.
|
| |
| bool | try_node (path_node *pNode, map_tile_flags flags, path_node *pNeighbour, travel_direction direction) override |
| | Try the pNeighbour node.
|
| |
| bool | find_idle_tile (const level_map *pMap, int iStartX, int iStartY, int iN, int parcelId) |
| |
| | abstract_pathfinder (pathfinder *pf) |
| |
| virtual | ~abstract_pathfinder ()=default |
| |
| path_node * | init (const level_map *pMap, int iStartX, int iStarty) |
| | Initialize the path finder.
|
| |
| bool | search_neighbours (path_node *pNode, map_tile_flags flags, int iWidth) |
| | Expand the pNode to its neighbours.
|
| |
| void | record_neighbour_if_passable (path_node *pNode, map_tile_flags neighbour_flags, bool passable, path_node *pNeighbour) |
| |
◆ idle_tile_finder()
| idle_tile_finder::idle_tile_finder |
( |
pathfinder * |
pf | ) |
|
|
inlineexplicit |
◆ find_idle_tile()
- Parameters
-
| pMap | Map to search. |
| iStartX | X coordinate of the start position. |
| iStartY | Y coordinate of the start position. |
| iN | Return the Nth idle tile. Used for queueing and randomizing idle tiles. |
| parcelId | Id of the parcel with valid destinations, use 0 for any parcel. |
◆ guess_distance()
◆ try_node()
Try the pNeighbour node.
- Parameters
-
| pNode | Source node. |
| flags | Flags of the node. |
| pNeighbour | Neighbour of pNode to try. |
| direction | Direction of travel. |
- Returns
- Whether the search is done.
Implements abstract_pathfinder.
◆ best_distance
| double idle_tile_finder::best_distance |
◆ best_next_node
◆ start_x
| int idle_tile_finder::start_x |
X coordinate of the start position.
◆ start_y
| int idle_tile_finder::start_y |
Y coordinate of the start position.
The documentation for this class was generated from the following files: