Use 0 for per-cargo percent loaded value when capacity is 0

This commit is contained in:
Jonathan G Rennison
2020-01-18 20:48:41 +00:00
parent 09b13dd484
commit 7611e1229c

View File

@@ -2171,7 +2171,7 @@ uint8 CalcPercentVehicleFilledOfCargo(const Vehicle *front, CargoID cargo)
} }
/* Train without capacity */ /* Train without capacity */
if (max == 0) return 100; if (max == 0) return 0;
/* Return the percentage */ /* Return the percentage */
if (count * 2 < max) { if (count * 2 < max) {