mirror of https://github.com/OpenTTD/OpenTTD
(svn r17601) -Fix (r17592): don't mark cargo as 'accepted' when accepted amount is 0
parent
8a003eb197
commit
494ef040e5
|
@ -432,7 +432,7 @@ static void AddAcceptedCargo_Industry(TileIndex tile, CargoArray &acceptance, ui
|
||||||
const Industry *ind = Industry::GetByTile(tile);
|
const Industry *ind = Industry::GetByTile(tile);
|
||||||
for (byte i = 0; i < lengthof(itspec->accepts_cargo); i++) {
|
for (byte i = 0; i < lengthof(itspec->accepts_cargo); i++) {
|
||||||
CargoID a = accepts_cargo[i];
|
CargoID a = accepts_cargo[i];
|
||||||
if (a == CT_INVALID) continue; // work only with valid cargos
|
if (a == CT_INVALID || cargo_acceptance[i] == 0) continue; // work only with valid cargos
|
||||||
|
|
||||||
/* Add accepted cargo */
|
/* Add accepted cargo */
|
||||||
acceptance[a] += cargo_acceptance[i];
|
acceptance[a] += cargo_acceptance[i];
|
||||||
|
|
Loading…
Reference in New Issue