fix #1333: added missing logic from finance_pay_ride_upkeep to make rides safe again

This commit is contained in:
IntelOrca 2016-01-07 19:20:11 +00:00
parent 73b0e403c4
commit 569026f36b
2 changed files with 6 additions and 1 deletions

View File

@ -7,6 +7,7 @@
- Feature: Allow enabling / disabling of different notifications.
- Feature: Improved tile inspector.
- Feature: Integrate RCT1 style scenario select with optional unlock progression.
- Fix: [#1333] Rides never become safe again after a crash.
- Fix: [#2126] Ferris Wheels set to "backward rotation" stop working (original bug)
- Fix: [#2449] Turning off Day/Night Circle while it is night doesn't reset back to day
- Fix: [#2650] Server did not validate actions send from clients (caused error box and desynchronisation)

View File

@ -132,8 +132,8 @@ void finance_pay_ride_upkeep()
if (!(ride->lifecycle_flags & RIDE_LIFECYCLE_EVER_BEEN_OPENED)) {
ride->build_date = RCT2_GLOBAL(RCT2_ADDRESS_CURRENT_MONTH_YEAR, uint16);
ride->reliability = RIDE_INITIAL_RELIABILITY;
}
if (ride->status != RIDE_STATUS_CLOSED && !(RCT2_GLOBAL(RCT2_ADDRESS_PARK_FLAGS, uint32) & PARK_FLAGS_NO_MONEY)) {
sint16 upkeep = ride->upkeep_cost;
if (upkeep != -1) {
@ -142,6 +142,10 @@ void finance_pay_ride_upkeep()
finance_payment(upkeep, RCT_EXPENDITURE_TYPE_RIDE_RUNNING_COSTS);
}
}
if (ride->last_crash_type != RIDE_CRASH_TYPE_NONE) {
ride->last_crash_type--;
}
}
}