#include "../stdafx.h"
#include "yapf.hpp"
#include "yapf_node_road.hpp"
Go to the source code of this file.
Data Structures | |
class | CYapfCostRoadT< Types > |
class | CYapfDestinationAnyDepotRoadT< Types > |
class | CYapfDestinationTileRoadT< Types > |
class | CYapfFollowRoadT< Types > |
struct | CYapfRoad_TypesT< Tpf_, Tnode_list, Tdestination > |
struct | CYapfRoad1 |
struct | CYapfRoad2 |
struct | CYapfRoadAnyDepot1 |
struct | CYapfRoadAnyDepot2 |
Functions | |
Trackdir | YapfChooseRoadTrack (Vehicle *v, TileIndex tile, DiagDirection enterdir) |
Finds the best path for given road vehicle. | |
uint | YapfRoadVehDistanceToTile (const Vehicle *v, TileIndex tile) |
Used by RV multistop feature to find the nearest road stop that has a free slot. | |
Depot * | YapfFindNearestRoadDepot (const Vehicle *v) |
Used when user sends RV to the nearest depot or if RV needs servicing. |
Definition in file yapf_road.cpp.
Trackdir YapfChooseRoadTrack | ( | Vehicle * | v, | |
TileIndex | tile, | |||
DiagDirection | enterdir | |||
) |
Finds the best path for given road vehicle.
v | the RV that needs to find a path | |
tile | the tile to find the path from (should be next tile the RV is about to enter) | |
enterdir | diagonal direction which the RV will enter this new tile from |
Definition at line 403 of file yapf_road.cpp.
Referenced by RoadFindPathToDest().
Depot* YapfFindNearestRoadDepot | ( | const Vehicle * | v | ) |
Used when user sends RV to the nearest depot or if RV needs servicing.
Returns the nearest depot (or NULL if depot was not found).
Definition at line 435 of file yapf_road.cpp.
References GetDepotByTile(), GetVehicleTrackdir(), IsTileDepotType(), IsTileType(), MP_ROAD, TrackdirToTrackdirBits(), and TrackStatusToTrackdirBits().
uint YapfRoadVehDistanceToTile | ( | const Vehicle * | v, | |
TileIndex | tile | |||
) |
Used by RV multistop feature to find the nearest road stop that has a free slot.
v | RV (its current tile will be the origin) | |
tile | destination tile |
Definition at line 417 of file yapf_road.cpp.