summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2008-06-04 06:40:07 +0000
committerpeter1138 <peter1138@openttd.org>2008-06-04 06:40:07 +0000
commitf78ea7c6bfecf75c4491e42f1a6596916d1e84ad (patch)
tree7513e171a4e87303f48ff658ca6cbe82b8f6a1d8 /src
parent2550f353e9159d6a63a0ab8cc777e519cfad5b08 (diff)
downloadopenttd-f78ea7c6bfecf75c4491e42f1a6596916d1e84ad.tar.xz
(svn r13377) -Codechange: Let 'long format' build year work in vehicle purchase list.
Diffstat (limited to 'src')
-rw-r--r--src/newgrf_engine.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/newgrf_engine.cpp b/src/newgrf_engine.cpp
index 1b9cc55ca..f809fcc67 100644
--- a/src/newgrf_engine.cpp
+++ b/src/newgrf_engine.cpp
@@ -476,6 +476,7 @@ static uint32 VehicleGetVariable(const ResolverObject *object, byte variable, by
case 0x43: return _current_player | (LiveryHelper(object->u.vehicle.self_type, NULL) << 24); // Owner information
case 0x46: return 0; // Motion counter
case 0x48: return GetEngine(object->u.vehicle.self_type)->flags; // Vehicle Type Info
+ case 0x49: return _cur_year; // 'Long' format build year
case 0xC4: return Clamp(_cur_year, ORIGINAL_BASE_YEAR, ORIGINAL_MAX_YEAR) - ORIGINAL_BASE_YEAR; // Build year
case 0xDA: return INVALID_VEHICLE; // Next vehicle
case 0x7F: return GetGRFParameter(object->u.vehicle.self_type, parameter); // Read GRF parameter