(svn r9802) -Fix: a vehicle without visual effects isn't per definition unpowered (mart3p).

This commit is contained in:
rubidium 2007-05-06 20:00:36 +00:00
parent 411985b13a
commit feadd86819

View File

@ -190,7 +190,7 @@ void TrainConsistChanged(Vehicle* v)
} }
if (rvi_v->pow_wag_power != 0 && rvi_u->railveh_type == RAILVEH_WAGON && if (rvi_v->pow_wag_power != 0 && rvi_u->railveh_type == RAILVEH_WAGON &&
UsesWagonOverride(u) && (u->u.rail.cached_vis_effect < 0x40)) { UsesWagonOverride(u) && !HASBIT(u->u.rail.cached_vis_effect, 7)) {
/* wagon is powered */ /* wagon is powered */
SETBIT(u->u.rail.flags, VRF_POWEREDWAGON); // cache 'powered' status SETBIT(u->u.rail.flags, VRF_POWEREDWAGON); // cache 'powered' status
} else { } else {