diff options
author | peter1138 <peter1138@openttd.org> | 2008-02-21 19:09:10 +0000 |
---|---|---|
committer | peter1138 <peter1138@openttd.org> | 2008-02-21 19:09:10 +0000 |
commit | dda6cab17a451da637b15ecdbfd6f8f64be9ab77 (patch) | |
tree | ea01512db1a1157040bbc860c2b76afcf0fe4eee /src/roadveh.h | |
parent | c0544563a608dcb2275c344a131bc0669694c550 (diff) | |
download | openttd-dda6cab17a451da637b15ecdbfd6f8f64be9ab77.tar.xz |
(svn r12209) -Fix: [NewGRF] Support using any base price for rail and road vehicles' running cost, and show running cost of wagons if they have it.
Diffstat (limited to 'src/roadveh.h')
-rw-r--r-- | src/roadveh.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/roadveh.h b/src/roadveh.h index 3beced163..fa6df94eb 100644 --- a/src/roadveh.h +++ b/src/roadveh.h @@ -72,7 +72,7 @@ struct RoadVehicle : public Vehicle { int GetImage(Direction direction) const; int GetDisplaySpeed() const { return this->cur_speed * 10 / 32; } int GetDisplayMaxSpeed() const { return this->max_speed * 10 / 32; } - Money GetRunningCost() const { return RoadVehInfo(this->engine_type)->running_cost * _price.roadveh_running; } + 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; } void Tick(); void OnNewDay(); |