mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-19 21:13:05 +01:00
add global for gPeepWarningThrottle
This commit is contained in:
@@ -283,6 +283,7 @@
|
||||
#define RCT2_ADDRESS_INITIAL_CASH 0x013573DC
|
||||
#define RCT2_ADDRESS_CURRENT_LOAN 0x013573E0
|
||||
#define RCT2_ADDRESS_MAXIMUM_LOAN 0x013580F0
|
||||
#define RCT2_ADDRESS_PEEP_WARNING_THROTTLE 0x01358750
|
||||
#define RCT2_ADDRESS_LOAN_HASH 0x013587C4
|
||||
#define RCT2_ADDRESS_PARK_FLAGS 0x013573E4
|
||||
#define RCT2_ADDRESS_PARK_ENTRANCE_FEE 0x013573E8
|
||||
|
||||
@@ -67,9 +67,11 @@ void news_item_init_queue()
|
||||
|
||||
news_item_get(0)->type = NEWS_ITEM_NULL;
|
||||
news_item_get(11)->type = NEWS_ITEM_NULL;
|
||||
|
||||
// Throttles for warning types (PEEP_*_WARNING)
|
||||
for (i = 0; i < 16; i++)
|
||||
RCT2_ADDRESS(0x01358750, uint8)[i] = 0;
|
||||
for (i = 0; i < 16; i++) {
|
||||
gPeepWarningThrottle[i] = 0;
|
||||
}
|
||||
|
||||
window_game_bottom_toolbar_invalidate_news_item();
|
||||
}
|
||||
|
||||
@@ -40,6 +40,8 @@
|
||||
#include "peep.h"
|
||||
#include "staff.h"
|
||||
|
||||
extern uint8 *gPeepWarningThrottle = RCT2_ADDRESS(RCT2_ADDRESS_PEEP_WARNING_THROTTLE, uint8);
|
||||
|
||||
enum {
|
||||
PATH_SEARCH_DEAD_END,
|
||||
PATH_SEARCH_RIDE_EXIT,
|
||||
@@ -5786,7 +5788,7 @@ void peep_problem_warnings_update()
|
||||
uint16 guests_in_park = gNumGuestsInPark;
|
||||
int hunger_counter = 0, lost_counter = 0, noexit_counter = 0, thirst_counter = 0,
|
||||
litter_counter = 0, disgust_counter = 0, bathroom_counter = 0 ,vandalism_counter = 0;
|
||||
uint8* warning_throttle = RCT2_ADDRESS(0x01358750, uint8);
|
||||
uint8 *warning_throttle = gPeepWarningThrottle;
|
||||
|
||||
RCT2_GLOBAL(RCT2_ADDRESS_RIDE_COUNT, sint16) = ride_get_count(); // refactor this to somewhere else
|
||||
|
||||
|
||||
@@ -607,6 +607,8 @@ enum {
|
||||
|
||||
#define gNextGuestNumber RCT2_GLOBAL(RCT2_ADDRESS_NEXT_GUEST_NUMBER, uint32)
|
||||
|
||||
extern uint8 *gPeepWarningThrottle;
|
||||
|
||||
int peep_get_staff_count();
|
||||
int peep_can_be_picked_up(rct_peep* peep);
|
||||
void peep_update_all();
|
||||
|
||||
@@ -339,7 +339,7 @@ void S6Exporter::Export()
|
||||
_s6.total_admissions = gTotalAdmissions;
|
||||
_s6.income_from_admissions = gTotalIncomeFromAdmissions;
|
||||
_s6.company_value = gCompanyValue;
|
||||
memcpy(_s6.byte_01358750, RCT2_ADDRESS(0x01358750, uint8), sizeof(_s6.byte_01358750));
|
||||
memcpy(_s6.peep_warning_throttle, gPeepWarningThrottle, sizeof(_s6.peep_warning_throttle));
|
||||
memcpy(_s6.awards, gCurrentAwards, sizeof(_s6.awards));
|
||||
_s6.land_price = gLandPrice;
|
||||
_s6.construction_rights_price = gConstructionRightsPrice;
|
||||
|
||||
@@ -271,7 +271,7 @@ void S6Importer::Import()
|
||||
gTotalAdmissions = _s6.total_admissions;
|
||||
gTotalIncomeFromAdmissions = _s6.income_from_admissions;
|
||||
gCompanyValue = _s6.company_value;
|
||||
memcpy(RCT2_ADDRESS(0x01358750, uint8), _s6.byte_01358750, sizeof(_s6.byte_01358750));
|
||||
memcpy(gPeepWarningThrottle, _s6.peep_warning_throttle, sizeof(_s6.peep_warning_throttle));
|
||||
memcpy(gCurrentAwards, _s6.awards, sizeof(_s6.awards));
|
||||
gLandPrice = _s6.land_price;
|
||||
gConstructionRightsPrice = _s6.construction_rights_price;
|
||||
|
||||
@@ -235,7 +235,7 @@ typedef struct {
|
||||
uint32 total_admissions;
|
||||
money32 income_from_admissions;
|
||||
money32 company_value;
|
||||
uint8 byte_01358750[16];
|
||||
uint8 peep_warning_throttle[16];
|
||||
rct_award awards[4];
|
||||
money16 land_price;
|
||||
money16 construction_rights_price;
|
||||
|
||||
Reference in New Issue
Block a user