summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-09-07 21:09:37 +0000
committerrubidium <rubidium@openttd.org>2007-09-07 21:09:37 +0000
commit8da977b4076b71089f8066f69fbbcf9b1370890f (patch)
tree50d72f71b8128dc073663a7f05246843f6bd8a76
parent5ad79a5db0de1eac743c3f5098a7ab73f3474a43 (diff)
downloadopenttd-8da977b4076b71089f8066f69fbbcf9b1370890f.tar.xz
(svn r11053) -Fix: train status bar flickering a lot when waiting at a signal.
-rw-r--r--src/train.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/train.h b/src/train.h
index db9e53c6a..1751e07e7 100644
--- a/src/train.h
+++ b/src/train.h
@@ -298,7 +298,7 @@ struct Train : public Vehicle {
bool IsPrimaryVehicle() const { return IsFrontEngine(this); }
bool HasFront() const { return true; }
int GetImage(Direction direction) const;
- int GetDisplaySpeed() const { return this->cur_speed * 10 / 16; }
+ int GetDisplaySpeed() const { return this->u.rail.last_speed * 10 / 16; }
int GetDisplayMaxSpeed() const { return this->u.rail.cached_max_speed * 10 / 16; }
Money GetRunningCost() const;
bool IsInDepot() const { return CheckTrainInDepot(this, false) != -1; }