(svn r8850) -Codechange: Use the cargo type's is_freight flag instead of checking the cargo type to determine if the cargo type is freight cargo type cargo type.
This commit is contained in:
@@ -49,8 +49,7 @@ static const TrackBits _state_dir_table[4] = { TRACK_BIT_RIGHT, TRACK_BIT_LOWER,
|
|||||||
*/
|
*/
|
||||||
byte FreightWagonMult(CargoID cargo)
|
byte FreightWagonMult(CargoID cargo)
|
||||||
{
|
{
|
||||||
// XXX NewCargos introduces a specific "is freight" flag for this test.
|
if (!GetCargo(cargo)->is_freight) return 1;
|
||||||
if (cargo == CT_PASSENGERS || cargo == CT_MAIL) return 1;
|
|
||||||
return _patches.freight_trains;
|
return _patches.freight_trains;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user