(svn r9875) -Fix (r9828): Only set carriage capacity if the wagon has not been refitted.

This commit is contained in:
peter1138 2007-05-19 10:29:51 +00:00
parent 7d4be11516
commit 60a2c5280e

View File

@ -221,7 +221,10 @@ void TrainConsistChanged(Vehicle* v)
}
}
u->cargo_cap = GetVehicleProperty(u, 0x14, rvi_u->capacity);
if (u->cargo_type == rvi_u->cargo_type && u->cargo_subtype == 0) {
/* Set cargo capacity if we've not been refitted */
u->cargo_cap = GetVehicleProperty(u, 0x14, rvi_u->capacity);
}
/* check the vehicle length (callback) */
uint16 veh_len = CALLBACK_FAILED;