Fix #19586: Guests generated have potentially a large amount of money

This commit is contained in:
ζeh Matt 2023-03-07 06:37:01 +02:00
parent 30e6eb9f08
commit ff1941eb8d
No known key found for this signature in database
GPG Key ID: 18CE582C71A225B0
1 changed files with 1 additions and 1 deletions

View File

@ -7130,7 +7130,7 @@ Guest* Guest::Generate(const CoordsXYZ& coords)
peep->PeepId = gNextGuestNumber++;
peep->Name = nullptr;
money64 cash = (ScenarioRand() & 0x3) * 100 - 100 + gGuestInitialCash;
money64 cash = (static_cast<money64>(ScenarioRand() & 0x3) * 100) - 100 + gGuestInitialCash;
if (cash < 0)
cash = 0;