Fix saves from corrupting due to old guests in park

RideTypesBeenOn and RidesBeenOn are not at this moment the type that they say they are so doing a check against that type gives invalid results.
This commit is contained in:
duncanspumpkin 2021-06-05 08:42:05 +01:00
parent 5bac7821c9
commit e45bcde09c
1 changed files with 2 additions and 2 deletions

View File

@ -1690,12 +1690,12 @@ namespace OpenRCT2
cs.ReadWrite(guest.NauseaTolerance);
cs.ReadWriteArray(guest.RideTypesBeenOn, [&cs](uint8_t& rideType) {
cs.ReadWrite(rideType);
return rideType != RIDE_TYPE_NULL;
return true;
});
cs.ReadWrite(guest.TimeInQueue);
cs.ReadWriteArray(guest.RidesBeenOn, [&cs](ride_id_t& rideId) {
cs.ReadWrite(rideId);
return rideId != RIDE_ID_NULL;
return true;
});
cs.ReadWrite(guest.CashInPocket);
cs.ReadWrite(guest.CashSpent);