![]() |
Freeciv21
Develop your civilization from humble roots to a global empire
|
A path finding destination that accepts any path leading to a specific tile. More...
#include <path_finder.h>
Inheritance diagram for freeciv::tile_destination:
Collaboration diagram for freeciv::tile_destination:Public Member Functions | |
| tile_destination (const tile *destination) | |
| Constructor. More... | |
| ~tile_destination () | |
| Destructor. More... | |
Public Member Functions inherited from freeciv::destination | |
| virtual | ~destination () |
| Destructor. More... | |
Protected Member Functions | |
| bool | reached (const detail::vertex &vertex) const override |
| Checks if a vertex should be considered as being at the destination. More... | |
| path_finder::storage_type::const_iterator | find_best (const path_finder::storage_type &map, std::size_t num_waypoints) const override |
| Returns an iterator to the best vertex that is a destination vertex. More... | |
Private Attributes | |
| const tile * | m_destination |
A path finding destination that accepts any path leading to a specific tile.
Definition at line 173 of file path_finder.h.
|
inlineexplicit |
Constructor.
Definition at line 178 of file path_finder.h.
|
inline |
Destructor.
Definition at line 187 of file path_finder.h.
|
overrideprotectedvirtual |
Returns an iterator to the best vertex that is a destination vertex.
The default implementation calls reached for every vertex.
This implementation only checks relevant nodes.
Reimplemented from freeciv::destination.
Definition at line 849 of file path_finder.cpp.
|
overrideprotectedvirtual |
Checks if a vertex should be considered as being at the destination.
Implements freeciv::destination.
Definition at line 838 of file path_finder.cpp.
Referenced by find_best().
|
private |
Definition at line 196 of file path_finder.h.
Referenced by find_best(), and reached().