mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-04 06:00:15 +00:00
(svn r24158) -Fix (r23408): Town producing no cargo at all could spawn passenger subsidies.
This commit is contained in:
parent
85cc8822cb
commit
56a5bf79cd
@ -336,6 +336,9 @@ bool FindSubsidyTownCargoRoute()
|
||||
/* Passenger subsidies are not handled here. */
|
||||
ClrBit(town_cargo_produced, CT_PASSENGERS);
|
||||
|
||||
/* No cargo produced at all? */
|
||||
if (town_cargo_produced == 0) return false;
|
||||
|
||||
/* Choose a random cargo that is produced in the town. */
|
||||
uint8 cargo_number = RandomRange(CountBits(town_cargo_produced));
|
||||
CargoID cid;
|
||||
|
Loading…
Reference in New Issue
Block a user