diff options
author | peter1138 <peter1138@openttd.org> | 2005-11-03 09:22:24 +0000 |
---|---|---|
committer | peter1138 <peter1138@openttd.org> | 2005-11-03 09:22:24 +0000 |
commit | e80d448478746ba30f1f78ad809e14703c7b899a (patch) | |
tree | 123239ecee67253d8657a7f2bff6334fce75a4d9 /vehicle.h | |
parent | 689006ee738c8866d05161cb8bbdd6d9a6472252 (diff) | |
download | openttd-e80d448478746ba30f1f78ad809e14703c7b899a.tar.xz |
(svn r3124) Alter train loading/unloading time to use the actual length of the train instead of the number of wagons. The actual length is cached in the first vehicle of the train.
Diffstat (limited to 'vehicle.h')
-rw-r--r-- | vehicle.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -57,6 +57,8 @@ typedef struct VehicleRail { uint16 cached_max_speed; // max speed of the consist. (minimum of the max speed of all vehicles in the consist) uint32 cached_power; // total power of the consist. uint8 cached_veh_length; // length of this vehicle in units of 1/8 of normal length, cached because this can be set by a callback + uint16 cached_total_length; ///< Length of the whole train, valid only for first engine. + // cached values, recalculated when the cargo on a train changes (in addition to the conditions above) uint16 cached_weight; // total weight of the consist. uint16 cached_veh_weight; // weight of the vehicle. |