summaryrefslogtreecommitdiff
path: root/src/base_station_base.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-07-24 15:18:25 +0000
committerrubidium <rubidium@openttd.org>2009-07-24 15:18:25 +0000
commitc3d2c47faa6bb9c07c362127b4fb5de79130bfa0 (patch)
tree6478960a00fd8d58956b9fdb0981ad1bf995f373 /src/base_station_base.h
parentcf38a5bee6628f4be58a1bd7774658cf86807d5c (diff)
downloadopenttd-c3d2c47faa6bb9c07c362127b4fb5de79130bfa0.tar.xz
(svn r16940) -Codechange: make the pathfinders behave the same when finding waypoints or stations, i.e. don't force exactly one destination tile for a waypoint
Diffstat (limited to 'src/base_station_base.h')
-rw-r--r--src/base_station_base.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/base_station_base.h b/src/base_station_base.h
index 407370260..a5dbd124f 100644
--- a/src/base_station_base.h
+++ b/src/base_station_base.h
@@ -85,6 +85,24 @@ struct BaseStation : StationPool::PoolItem<&_station_pool> {
*/
virtual void GetTileArea(TileArea *ta, StationType type) const = 0;
+
+ /**
+ * Obtain the length of a platform
+ * @pre tile must be a rail station tile
+ * @param tile A tile that contains the platform in question
+ * @return The length of the platform
+ */
+ virtual uint GetPlatformLength(TileIndex tile, DiagDirection dir) const = 0;
+
+ /**
+ * Determines the REMAINING length of a platform, starting at (and including)
+ * the given tile.
+ * @param tile the tile from which to start searching. Must be a rail station tile
+ * @param dir The direction in which to search.
+ * @return The platform length
+ */
+ virtual uint GetPlatformLength(TileIndex tile) const = 0;
+
/**
* Get the base station belonging to a specific tile.
* @param tile The tile to get the base station from.