summaryrefslogtreecommitdiff
path: root/src/roadveh.h
diff options
context:
space:
mode:
authorterkhen <terkhen@openttd.org>2010-11-06 13:05:11 +0000
committerterkhen <terkhen@openttd.org>2010-11-06 13:05:11 +0000
commit18e3a3ddfc7c9eee4d1023485a4c23b3cc40fbb3 (patch)
tree719e279d32005d7032a509a6aea06ab70124a667 /src/roadveh.h
parent25d1b2f54b9cac01e2737848c208f6d8096a4a92 (diff)
downloadopenttd-18e3a3ddfc7c9eee4d1023485a4c23b3cc40fbb3.tar.xz
(svn r21099) -Codechange: Store road vehicle max speed in the vehicle cache.
Diffstat (limited to 'src/roadveh.h')
-rw-r--r--src/roadveh.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/roadveh.h b/src/roadveh.h
index a8fcccd00..96a86bafa 100644
--- a/src/roadveh.h
+++ b/src/roadveh.h
@@ -119,7 +119,7 @@ struct RoadVehicle : public GroundVehicle<RoadVehicle, VEH_ROAD> {
bool IsPrimaryVehicle() const { return this->IsRoadVehFront(); }
SpriteID GetImage(Direction direction) const;
int GetDisplaySpeed() const { return this->cur_speed / 2; }
- int GetDisplayMaxSpeed() const { return this->max_speed / 2; }
+ int GetDisplayMaxSpeed() const { return this->vcache.cached_max_speed / 2; }
Money GetRunningCost() const;
int GetDisplayImageWidth(Point *offset = NULL) const;
bool IsInDepot() const { return this->state == RVSB_IN_DEPOT; }