summaryrefslogtreecommitdiff
path: root/src/vehicle.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-08-26 20:43:22 +0000
committerrubidium <rubidium@openttd.org>2007-08-26 20:43:22 +0000
commita5b32d8d7238ae769a9dc3bcc71aaaba213058b9 (patch)
tree774788b69d486a12f8c1135fa3ca8e087d508d2a /src/vehicle.h
parenta83ccad6bd289715da504f9ab514ac781ece5608 (diff)
downloadopenttd-a5b32d8d7238ae769a9dc3bcc71aaaba213058b9.tar.xz
(svn r10984) -Codechange: unify the way one can get the current speed in the same forwat so we can display it.
Diffstat (limited to 'src/vehicle.h')
-rw-r--r--src/vehicle.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/vehicle.h b/src/vehicle.h
index 63f4203ee..cb0c78809 100644
--- a/src/vehicle.h
+++ b/src/vehicle.h
@@ -415,6 +415,12 @@ struct Vehicle : PoolItem<Vehicle, VehicleID, &_Vehicle_pool> {
virtual int GetImage(Direction direction) const { return 0; }
/**
+ * Gets the speed in mph that can be sent into SetDParam for string processing.
+ * @return the vehicle's speed
+ */
+ virtual int GetDisplaySpeed() const { return 0; }
+
+ /**
* Calls the tick handler of the vehicle
*/
virtual void Tick() {};