summaryrefslogtreecommitdiff
path: root/src/train_cmd.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-04-21 14:33:33 +0000
committerrubidium <rubidium@openttd.org>2008-04-21 14:33:33 +0000
commite947fde7013a09d58744604faaf3c574dae51c47 (patch)
tree4c1ef67d89a0fbc13b10c3ed8a9880350b14ab12 /src/train_cmd.cpp
parentbbe13a0623eea9f46353fca57a35ae745040fbaf (diff)
downloadopenttd-e947fde7013a09d58744604faaf3c574dae51c47.tar.xz
(svn r12819) -Codechange: handle more NewGRFs in the same way as TTDP does it, i.e. testing the low bits for 0xFF or 0 instead of all bits.
Diffstat (limited to 'src/train_cmd.cpp')
-rw-r--r--src/train_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/train_cmd.cpp b/src/train_cmd.cpp
index 4f55e30ce..a1a378602 100644
--- a/src/train_cmd.cpp
+++ b/src/train_cmd.cpp
@@ -240,7 +240,7 @@ void TrainConsistChanged(Vehicle *v)
if (HasBit(EngInfo(u->engine_type)->callbackmask, CBM_TRAIN_WAGON_POWER)) {
uint16 callback = GetVehicleCallback(CBID_TRAIN_WAGON_POWER, 0, 0, u->engine_type, u);
- if (callback != CALLBACK_FAILED) u->u.rail.cached_vis_effect = callback;
+ if (callback != CALLBACK_FAILED) u->u.rail.cached_vis_effect = GB(callback, 0, 8);
}
if (rvi_v->pow_wag_power != 0 && rvi_u->railveh_type == RAILVEH_WAGON &&