summaryrefslogtreecommitdiff
path: root/src/newgrf.cpp
diff options
context:
space:
mode:
authormichi_cc <michi_cc@openttd.org>2011-12-03 23:40:46 +0000
committermichi_cc <michi_cc@openttd.org>2011-12-03 23:40:46 +0000
commitd3b7b89493e025654d218fb77da095649b4f6ba2 (patch)
tree6667e4164c5c8bda4c1b7092376872b315c65610 /src/newgrf.cpp
parentf98312eb77e12cfa45de40a1b4e8359160b0d9ff (diff)
downloadopenttd-d3b7b89493e025654d218fb77da095649b4f6ba2.tar.xz
(svn r23415) -Feature: Infrastructure maintenance costs.
Diffstat (limited to 'src/newgrf.cpp')
-rw-r--r--src/newgrf.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index 5a2175737..49e8cf3eb 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -3635,6 +3635,10 @@ static ChangeInfoResult AirportChangeInfo(uint airport, int numinfo, int prop, B
_string_to_grf_mapping[&as->name] = _cur.grffile->grfid;
break;
+ case 0x11: // Maintenance cost factor
+ as->maintenance_cost = buf->ReadWord();
+ break;
+
default:
ret = CIR_UNKNOWN;
break;
@@ -3941,6 +3945,10 @@ static ChangeInfoResult RailTypeChangeInfo(uint id, int numinfo, int prop, ByteR
_string_to_grf_mapping[&rti->strings.name] = _cur.grffile->grfid;
break;
+ case 0x1C: // Maintenance cost factor
+ rti->maintenance_multiplier = buf->ReadWord();
+ break;
+
default:
ret = CIR_UNKNOWN;
break;
@@ -3984,6 +3992,7 @@ static ChangeInfoResult RailTypeReserveInfo(uint id, int numinfo, int prop, Byte
case 0x13: // Construction cost
case 0x14: // Speed limit
case 0x1B: // Name of railtype
+ case 0x1C: // Maintenance cost factor
buf->ReadWord();
break;