diff options
author | frosch <frosch@openttd.org> | 2009-02-01 17:14:39 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2009-02-01 17:14:39 +0000 |
commit | 61a893d6fd341515c5d0fea254c5ea25849afa58 (patch) | |
tree | c6c194df7208fda252250f6a43df63be15b1bd2d /src/roadveh.h | |
parent | be395d0f3dfb525c599fc245498bb8af0437ba44 (diff) | |
download | openttd-61a893d6fd341515c5d0fea254c5ea25849afa58.tar.xz |
(svn r15308) -Codechange: Deduplicate km-ish/h -> mph conversions.
Diffstat (limited to 'src/roadveh.h')
-rw-r--r-- | src/roadveh.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/roadveh.h b/src/roadveh.h index 305a76e9a..5e1b7f455 100644 --- a/src/roadveh.h +++ b/src/roadveh.h @@ -74,8 +74,8 @@ struct RoadVehicle : public Vehicle { ExpensesType GetExpenseType(bool income) const { return income ? EXPENSES_ROADVEH_INC : EXPENSES_ROADVEH_RUN; } bool IsPrimaryVehicle() const { return IsRoadVehFront(this); } SpriteID GetImage(Direction direction) const; - int GetDisplaySpeed() const { return this->cur_speed * 10 / 32; } - int GetDisplayMaxSpeed() const { return this->max_speed * 10 / 32; } + int GetDisplaySpeed() const { return this->cur_speed / 2; } + int GetDisplayMaxSpeed() const { return this->max_speed / 2; } Money GetRunningCost() const { return RoadVehInfo(this->engine_type)->running_cost * GetPriceByIndex(RoadVehInfo(this->engine_type)->running_cost_class); } bool IsInDepot() const { return this->u.road.state == RVSB_IN_DEPOT; } bool IsStoppedInDepot() const; |