From e5ead99c8363483ce015f5fd4b4522cb92e73824 Mon Sep 17 00:00:00 2001 From: Aaron van Geffen Date: Wed, 13 Aug 2025 21:20:13 +0200 Subject: [PATCH] Move .numGuestsInPark, .guestsInParkHistory into ParkData struct --- src/openrct2-ui/windows/GameBottomToolbar.cpp | 7 ++--- src/openrct2-ui/windows/Park.cpp | 10 +++---- src/openrct2/Editor.cpp | 2 +- src/openrct2/Game.cpp | 6 ++--- src/openrct2/GameState.h | 6 ++--- src/openrct2/entity/Peep.cpp | 20 +++++++------- src/openrct2/management/Award.cpp | 12 ++++----- .../network/NetworkServerAdvertiser.cpp | 2 +- src/openrct2/park/ParkFile.cpp | 4 +-- src/openrct2/park/ParkPreview.cpp | 2 +- src/openrct2/rct1/S4Importer.cpp | 6 ++--- src/openrct2/rct2/S6Importer.cpp | 4 +-- src/openrct2/scenario/Scenario.cpp | 4 +-- .../scripting/bindings/world/ScPark.cpp | 2 +- src/openrct2/world/Park.cpp | 27 ++++++++++--------- src/openrct2/world/ParkData.h | 3 +++ 16 files changed, 60 insertions(+), 57 deletions(-) diff --git a/src/openrct2-ui/windows/GameBottomToolbar.cpp b/src/openrct2-ui/windows/GameBottomToolbar.cpp index 46c9ffd6df..ddf623031b 100644 --- a/src/openrct2-ui/windows/GameBottomToolbar.cpp +++ b/src/openrct2-ui/windows/GameBottomToolbar.cpp @@ -130,11 +130,12 @@ namespace OpenRCT2::Ui::Windows const auto& widget = widgets[WIDX_GUESTS]; auto screenCoords = ScreenCoordsXY{ windowPos.x + widget.midX(), windowPos.y + widget.midY() - 6 }; - StringId stringId = gameState.numGuestsInPark == 1 ? _guestCountFormatsSingular[gameState.guestChangeModifier] - : _guestCountFormats[gameState.guestChangeModifier]; + StringId stringId = gameState.park.numGuestsInPark == 1 + ? _guestCountFormatsSingular[gameState.guestChangeModifier] + : _guestCountFormats[gameState.guestChangeModifier]; auto colour = GetHoverWidgetColour(WIDX_GUESTS); auto ft = Formatter(); - ft.Add(gameState.numGuestsInPark); + ft.Add(gameState.park.numGuestsInPark); DrawTextBasic(rt, screenCoords, stringId, ft, { colour, TextAlignment::CENTRE }); } diff --git a/src/openrct2-ui/windows/Park.cpp b/src/openrct2-ui/windows/Park.cpp index eef2830394..d25cc93fcc 100644 --- a/src/openrct2-ui/windows/Park.cpp +++ b/src/openrct2-ui/windows/Park.cpp @@ -750,7 +750,7 @@ namespace OpenRCT2::Ui::Windows WindowAlignTabs(this, WIDX_TAB_1, WIDX_TAB_7); const auto& gameState = getGameState(); - _guestProps.series = gameState.guestsInParkHistory; + _guestProps.series = gameState.park.guestsInParkHistory; const Widget* background = &widgets[WIDX_PAGE_BACKGROUND]; _guestGraphBounds = { windowPos + ScreenCoordsXY{ background->left + 4, background->top + 15 }, windowPos + ScreenCoordsXY{ background->right - 4, background->bottom - 4 } }; @@ -758,9 +758,9 @@ namespace OpenRCT2::Ui::Windows // Calculate Y axis max and min _guestProps.min = 0; _guestProps.max = 5000; - for (size_t i = 0; i < std::size(gameState.guestsInParkHistory); i++) + for (size_t i = 0; i < std::size(gameState.park.guestsInParkHistory); i++) { - auto value = gameState.guestsInParkHistory[i]; + auto value = gameState.park.guestsInParkHistory[i]; if (value == kGuestsInParkHistoryUndefined) continue; while (value > _guestProps.max) @@ -786,7 +786,7 @@ namespace OpenRCT2::Ui::Windows // Current value Formatter ft; - ft.Add(getGameState().numGuestsInPark); + ft.Add(getGameState().park.numGuestsInPark); DrawTextBasic(rt, windowPos + ScreenCoordsXY{ widget->left + 3, widget->top + 2 }, STR_GUESTS_IN_PARK_LABEL, ft); // Graph border @@ -978,7 +978,7 @@ namespace OpenRCT2::Ui::Windows // Draw number of guests in park ft = Formatter(); - ft.Add(gameState.numGuestsInPark); + ft.Add(gameState.park.numGuestsInPark); DrawTextBasic(rt, screenCoords, STR_GUESTS_IN_PARK_LABEL, ft); screenCoords.y += kListRowHeight; diff --git a/src/openrct2/Editor.cpp b/src/openrct2/Editor.cpp index e57895caaf..77d8fea42d 100644 --- a/src/openrct2/Editor.cpp +++ b/src/openrct2/Editor.cpp @@ -302,7 +302,7 @@ namespace OpenRCT2::Editor ResetAllEntities(); UpdateConsolidatedPatrolAreas(); - gameState.numGuestsInPark = 0; + gameState.park.numGuestsInPark = 0; gameState.numGuestsHeadingForPark = 0; gameState.numGuestsInParkLastWeek = 0; gameState.guestChangeModifier = 0; diff --git a/src/openrct2/Game.cpp b/src/openrct2/Game.cpp index 0fd858f5f4..496b95bb9b 100644 --- a/src/openrct2/Game.cpp +++ b/src/openrct2/Game.cpp @@ -218,12 +218,12 @@ static void FixGuestCount() } auto& gameState = getGameState(); - if (gameState.numGuestsInPark != guestCount) + if (gameState.park.numGuestsInPark != guestCount) { - LOG_WARNING("Corrected bad amount of guests in park: %u -> %u", gameState.numGuestsInPark, guestCount); + LOG_WARNING("Corrected bad amount of guests in park: %u -> %u", gameState.park.numGuestsInPark, guestCount); } - gameState.numGuestsInPark = guestCount; + gameState.park.numGuestsInPark = guestCount; } static void FixPeepsWithInvalidRideReference() diff --git a/src/openrct2/GameState.h b/src/openrct2/GameState.h index 55236fa426..27cb7b695c 100644 --- a/src/openrct2/GameState.h +++ b/src/openrct2/GameState.h @@ -41,9 +41,6 @@ namespace OpenRCT2 uint32_t currentTicks{}; Date date; - money64 constructionRightsPrice; - uint32_t guestsInParkHistory[kGuestsInParkHistorySize]; - WeatherState weatherCurrent; WeatherState weatherNext; uint16_t weatherUpdateTimer; @@ -55,7 +52,7 @@ namespace OpenRCT2 uint8_t guestInitialThirst; uint8_t guestChangeModifier; uint32_t nextGuestNumber; - uint32_t numGuestsInPark; + uint32_t numGuestsHeadingForPark; uint32_t numGuestsInParkLastWeek; money64 weeklyProfitAverageDividend; @@ -74,6 +71,7 @@ namespace OpenRCT2 random_engine_t scenarioRand; TileCoordsXY mapSize; money64 landPrice; + money64 constructionRightsPrice; EditorStep editorStep; diff --git a/src/openrct2/entity/Peep.cpp b/src/openrct2/entity/Peep.cpp index 94d2a28a5d..3a31941032 100644 --- a/src/openrct2/entity/Peep.cpp +++ b/src/openrct2/entity/Peep.cpp @@ -1041,7 +1041,7 @@ void PeepProblemWarningsUpdate() // could maybe be packed into a loop, would lose a lot of clarity though if (warningThrottle[0]) --warningThrottle[0]; - else if (hungerCounter >= kPeepHungerWarningThreshold && hungerCounter >= gameState.numGuestsInPark / 16) + else if (hungerCounter >= kPeepHungerWarningThreshold && hungerCounter >= gameState.park.numGuestsInPark / 16) { warningThrottle[0] = 4; if (Config::Get().notifications.GuestWarnings) @@ -1053,7 +1053,7 @@ void PeepProblemWarningsUpdate() if (warningThrottle[1]) --warningThrottle[1]; - else if (thirstCounter >= kPeepThirstWarningThreshold && thirstCounter >= gameState.numGuestsInPark / 16) + else if (thirstCounter >= kPeepThirstWarningThreshold && thirstCounter >= gameState.park.numGuestsInPark / 16) { warningThrottle[1] = 4; if (Config::Get().notifications.GuestWarnings) @@ -1065,7 +1065,7 @@ void PeepProblemWarningsUpdate() if (warningThrottle[2]) --warningThrottle[2]; - else if (toiletCounter >= kPeepToiletWarningThreshold && toiletCounter >= gameState.numGuestsInPark / 16) + else if (toiletCounter >= kPeepToiletWarningThreshold && toiletCounter >= gameState.park.numGuestsInPark / 16) { warningThrottle[2] = 4; if (Config::Get().notifications.GuestWarnings) @@ -1077,7 +1077,7 @@ void PeepProblemWarningsUpdate() if (warningThrottle[3]) --warningThrottle[3]; - else if (litterCounter >= kPeepLitterWarningThreshold && litterCounter >= gameState.numGuestsInPark / 32) + else if (litterCounter >= kPeepLitterWarningThreshold && litterCounter >= gameState.park.numGuestsInPark / 32) { warningThrottle[3] = 4; if (Config::Get().notifications.GuestWarnings) @@ -1089,7 +1089,7 @@ void PeepProblemWarningsUpdate() if (warningThrottle[4]) --warningThrottle[4]; - else if (disgustCounter >= kPeepDisgustWarningThreshold && disgustCounter >= gameState.numGuestsInPark / 32) + else if (disgustCounter >= kPeepDisgustWarningThreshold && disgustCounter >= gameState.park.numGuestsInPark / 32) { warningThrottle[4] = 4; if (Config::Get().notifications.GuestWarnings) @@ -1101,7 +1101,7 @@ void PeepProblemWarningsUpdate() if (warningThrottle[5]) --warningThrottle[5]; - else if (vandalismCounter >= kPeepVandalismWarningThreshold && vandalismCounter >= gameState.numGuestsInPark / 32) + else if (vandalismCounter >= kPeepVandalismWarningThreshold && vandalismCounter >= gameState.park.numGuestsInPark / 32) { warningThrottle[5] = 4; if (Config::Get().notifications.GuestWarnings) @@ -2591,9 +2591,9 @@ void PeepUpdateNames() void IncrementGuestsInPark() { auto& gameState = getGameState(); - if (gameState.numGuestsInPark < UINT32_MAX) + if (gameState.park.numGuestsInPark < UINT32_MAX) { - gameState.numGuestsInPark++; + gameState.park.numGuestsInPark++; } else { @@ -2617,9 +2617,9 @@ void IncrementGuestsHeadingForPark() void DecrementGuestsInPark() { auto& gameState = getGameState(); - if (gameState.numGuestsInPark > 0) + if (gameState.park.numGuestsInPark > 0) { - gameState.numGuestsInPark--; + gameState.park.numGuestsInPark--; } else { diff --git a/src/openrct2/management/Award.cpp b/src/openrct2/management/Award.cpp index f08ada6a8d..97ab4cd90f 100644 --- a/src/openrct2/management/Award.cpp +++ b/src/openrct2/management/Award.cpp @@ -108,7 +108,7 @@ static bool AwardIsDeservedMostUntidy(int32_t activeAwardTypes) } } - return (negativeCount > getGameState().numGuestsInPark / 16); + return (negativeCount > getGameState().park.numGuestsInPark / 16); } /** More than 1/64 of the total guests must be thinking tidy thoughts and less than 6 guests thinking untidy thoughts. */ @@ -140,7 +140,7 @@ static bool AwardIsDeservedMostTidy(int32_t activeAwardTypes) } } - return (negativeCount <= 5 && positiveCount > getGameState().numGuestsInPark / 64); + return (negativeCount <= 5 && positiveCount > getGameState().park.numGuestsInPark / 64); } /** At least 6 open roller coasters. */ @@ -223,7 +223,7 @@ static bool AwardIsDeservedMostBeautiful(int32_t activeAwardTypes) } } - return (negativeCount <= 15 && positiveCount > getGameState().numGuestsInPark / 128); + return (negativeCount <= 15 && positiveCount > getGameState().park.numGuestsInPark / 128); } /** Entrance fee is more than total ride value. */ @@ -313,7 +313,7 @@ static bool AwardIsDeservedBestFood(int32_t activeAwardTypes) } } - if (shops < 7 || uniqueShops < 4 || shops < getGameState().numGuestsInPark / 128) + if (shops < 7 || uniqueShops < 4 || shops < getGameState().park.numGuestsInPark / 128) return false; // Count hungry peeps @@ -358,7 +358,7 @@ static bool AwardIsDeservedWorstFood(int32_t activeAwardTypes) } } - if (uniqueShops > 2 || shops > getGameState().numGuestsInPark / 256) + if (uniqueShops > 2 || shops > getGameState().park.numGuestsInPark / 256) return false; // Count hungry peeps @@ -390,7 +390,7 @@ static bool AwardIsDeservedBestToilets([[maybe_unused]] int32_t activeAwardTypes return false; // At least one open toilet for every 128 guests - if (numToilets < getGameState().numGuestsInPark / 128u) + if (numToilets < getGameState().park.numGuestsInPark / 128u) return false; // Count number of guests who are thinking they need the toilet diff --git a/src/openrct2/network/NetworkServerAdvertiser.cpp b/src/openrct2/network/NetworkServerAdvertiser.cpp index 3516e59e4e..f03909882e 100644 --- a/src/openrct2/network/NetworkServerAdvertiser.cpp +++ b/src/openrct2/network/NetworkServerAdvertiser.cpp @@ -310,7 +310,7 @@ private: { "mapSize", mapSize }, { "day", date.GetMonthTicks() }, { "month", date.GetMonthsElapsed() }, - { "guests", gameState.numGuestsInPark }, + { "guests", gameState.park.numGuestsInPark }, { "parkValue", gameState.park.Value }, }; diff --git a/src/openrct2/park/ParkFile.cpp b/src/openrct2/park/ParkFile.cpp index ff739a6bdc..d01a510011 100644 --- a/src/openrct2/park/ParkFile.cpp +++ b/src/openrct2/park/ParkFile.cpp @@ -979,7 +979,7 @@ namespace OpenRCT2 cs.ReadWrite(gameState.park.Value); cs.ReadWrite(gameState.park.companyValue); cs.ReadWrite(gameState.park.Size); - cs.ReadWrite(gameState.numGuestsInPark); + cs.ReadWrite(gameState.park.numGuestsInPark); cs.ReadWrite(gameState.numGuestsHeadingForPark); cs.ReadWrite(gameState.park.Rating); cs.ReadWrite(gameState.park.RatingCasualtyPenalty); @@ -1056,7 +1056,7 @@ namespace OpenRCT2 }); } - cs.ReadWriteArray(gameState.guestsInParkHistory, [&cs](uint32_t& value) { + cs.ReadWriteArray(gameState.park.guestsInParkHistory, [&cs](uint32_t& value) { cs.ReadWrite(value); return true; }); diff --git a/src/openrct2/park/ParkPreview.cpp b/src/openrct2/park/ParkPreview.cpp index ade4bc9b67..19dbed2703 100644 --- a/src/openrct2/park/ParkPreview.cpp +++ b/src/openrct2/park/ParkPreview.cpp @@ -40,7 +40,7 @@ namespace OpenRCT2 .parkUsesMoney = !(gameState.park.Flags & PARK_FLAGS_NO_MONEY), .cash = gameState.park.cash, .numRides = static_cast(RideManager().size()), - .numGuests = static_cast(gameState.numGuestsInPark), + .numGuests = static_cast(gameState.park.numGuestsInPark), }; if (auto image = generatePreviewMap(); image != std::nullopt) diff --git a/src/openrct2/rct1/S4Importer.cpp b/src/openrct2/rct1/S4Importer.cpp index dd52e7959c..40c466983e 100644 --- a/src/openrct2/rct1/S4Importer.cpp +++ b/src/openrct2/rct1/S4Importer.cpp @@ -2277,7 +2277,7 @@ namespace OpenRCT2::RCT1 { if (_s4.GuestsInParkHistory[i] != kRCT12ParkHistoryUndefined) { - gameState.guestsInParkHistory[i] = _s4.GuestsInParkHistory[i] * kRCT12GuestsInParkHistoryFactor; + gameState.park.guestsInParkHistory[i] = _s4.GuestsInParkHistory[i] * kRCT12GuestsInParkHistoryFactor; } } @@ -2293,13 +2293,13 @@ namespace OpenRCT2::RCT1 // Number of guests history std::fill( - std::begin(gameState.guestsInParkHistory), std::end(gameState.guestsInParkHistory), + std::begin(gameState.park.guestsInParkHistory), std::end(gameState.park.guestsInParkHistory), std::numeric_limits::max()); for (size_t i = 0; i < std::size(_s4.GuestsInParkHistory); i++) { if (_s4.GuestsInParkHistory[i] != std::numeric_limits::max()) { - gameState.guestsInParkHistory[i] = _s4.GuestsInParkHistory[i] * 20; + gameState.park.guestsInParkHistory[i] = _s4.GuestsInParkHistory[i] * 20; } } diff --git a/src/openrct2/rct2/S6Importer.cpp b/src/openrct2/rct2/S6Importer.cpp index e927f25ccf..199743e6a6 100644 --- a/src/openrct2/rct2/S6Importer.cpp +++ b/src/openrct2/rct2/S6Importer.cpp @@ -407,7 +407,7 @@ namespace OpenRCT2::RCT2 // _s6.ResearchedTrackTypesA // _s6.ResearchedTrackTypesB - gameState.numGuestsInPark = _s6.GuestsInPark; + gameState.park.numGuestsInPark = _s6.GuestsInPark; gameState.numGuestsHeadingForPark = _s6.GuestsHeadingForPark; for (size_t i = 0; i < Limits::kExpenditureTableMonthCount; i++) @@ -438,7 +438,7 @@ namespace OpenRCT2::RCT2 { if (_s6.GuestsInParkHistory[i] != kRCT12ParkHistoryUndefined) { - gameState.guestsInParkHistory[i] = _s6.GuestsInParkHistory[i] * kRCT12GuestsInParkHistoryFactor; + gameState.park.guestsInParkHistory[i] = _s6.GuestsInParkHistory[i] * kRCT12GuestsInParkHistoryFactor; } } diff --git a/src/openrct2/scenario/Scenario.cpp b/src/openrct2/scenario/Scenario.cpp index 3f82b42070..bfb62ea588 100644 --- a/src/openrct2/scenario/Scenario.cpp +++ b/src/openrct2/scenario/Scenario.cpp @@ -609,7 +609,7 @@ ObjectiveStatus Objective::CheckGuestsBy() const if (currentMonthYear == MONTH_COUNT * Year || AllowEarlyCompletion()) { - if (parkRating >= 600 && getGameState().numGuestsInPark >= NumGuests) + if (parkRating >= 600 && getGameState().park.numGuestsInPark >= NumGuests) { return ObjectiveStatus::Success; } @@ -730,7 +730,7 @@ ObjectiveStatus Objective::CheckGuestsAndRating() const } if (gameState.park.Rating >= 700) - if (gameState.numGuestsInPark >= NumGuests) + if (gameState.park.numGuestsInPark >= NumGuests) return ObjectiveStatus::Success; return ObjectiveStatus::Undecided; diff --git a/src/openrct2/scripting/bindings/world/ScPark.cpp b/src/openrct2/scripting/bindings/world/ScPark.cpp index 3a78ed1356..9cae4425b3 100644 --- a/src/openrct2/scripting/bindings/world/ScPark.cpp +++ b/src/openrct2/scripting/bindings/world/ScPark.cpp @@ -139,7 +139,7 @@ namespace OpenRCT2::Scripting uint32_t ScPark::guests_get() const { - return getGameState().numGuestsInPark; + return getGameState().park.numGuestsInPark; } uint32_t ScPark::suggestedGuestMaximum_get() const diff --git a/src/openrct2/world/Park.cpp b/src/openrct2/world/Park.cpp index 7a66d57fc4..2dc038d8fc 100644 --- a/src/openrct2/world/Park.cpp +++ b/src/openrct2/world/Park.cpp @@ -183,7 +183,7 @@ namespace OpenRCT2::Park uint32_t probability = 50 + std::clamp(gameState.park.Rating - 200, 0, 650); // The more guests, the lower the chance of a new one - uint32_t numGuests = gameState.numGuestsInPark + gameState.numGuestsHeadingForPark; + uint32_t numGuests = gameState.park.numGuestsInPark + gameState.numGuestsHeadingForPark; if (numGuests > gameState.suggestedGuestMaximum) { probability /= 4; @@ -235,7 +235,7 @@ namespace OpenRCT2::Park if (static_cast(ScenarioRand() & 0xFFFF) < gameState.guestGenerationProbability) { bool difficultGeneration = (gameState.park.Flags & PARK_FLAGS_DIFFICULT_GUEST_GENERATION) != 0; - if (!difficultGeneration || gameState.suggestedGuestMaximum + 150 >= gameState.numGuestsInPark) + if (!difficultGeneration || gameState.suggestedGuestMaximum + 150 >= gameState.park.numGuestsInPark) { GenerateGuest(); } @@ -281,7 +281,7 @@ namespace OpenRCT2::Park gameState.staffHandymanColour = COLOUR_BRIGHT_RED; gameState.staffMechanicColour = COLOUR_LIGHT_BLUE; gameState.staffSecurityColour = COLOUR_YELLOW; - gameState.numGuestsInPark = 0; + gameState.park.numGuestsInPark = 0; gameState.numGuestsInParkLastWeek = 0; gameState.numGuestsHeadingForPark = 0; gameState.guestChangeModifier = 0; @@ -410,7 +410,7 @@ namespace OpenRCT2::Park // Guests { // -150 to +3 based on a range of guests from 0 to 2000 - result -= 150 - (std::min(2000, gameState.numGuestsInPark) / 13); + result -= 150 - (std::min(2000, gameState.park.numGuestsInPark) / 13); // Find the number of happy peeps and the number of peeps who can't find the park exit uint32_t happyGuestCount = 0; @@ -432,9 +432,9 @@ namespace OpenRCT2::Park // Peep happiness -500 to +0 result -= 500; - if (gameState.numGuestsInPark > 0) + if (gameState.park.numGuestsInPark > 0) { - result += 2 * std::min(250u, (happyGuestCount * 300) / gameState.numGuestsInPark); + result += 2 * std::min(250u, (happyGuestCount * 300) / gameState.park.numGuestsInPark); } // Up to 25 guests can be lost without affecting the park rating. @@ -520,7 +520,7 @@ namespace OpenRCT2::Park } // +7.00 per guest - result += static_cast(getGameState().numGuestsInPark) * 7.00_GBP; + result += static_cast(getGameState().park.numGuestsInPark) * 7.00_GBP; return result; } @@ -586,13 +586,14 @@ namespace OpenRCT2::Park std::fill( std::begin(gameState.park.RatingHistory), std::end(gameState.park.RatingHistory), kParkRatingHistoryUndefined); std::fill( - std::begin(gameState.guestsInParkHistory), std::end(gameState.guestsInParkHistory), kGuestsInParkHistoryUndefined); + std::begin(gameState.park.guestsInParkHistory), std::end(gameState.park.guestsInParkHistory), + kGuestsInParkHistoryUndefined); } void UpdateHistories(GameState_t& gameState) { uint8_t guestChangeModifier = 1; - int32_t changeInGuestsInPark = static_cast(gameState.numGuestsInPark) + int32_t changeInGuestsInPark = static_cast(gameState.park.numGuestsInPark) - static_cast(gameState.numGuestsInParkLastWeek); if (changeInGuestsInPark > -20) { @@ -603,15 +604,15 @@ namespace OpenRCT2::Park } } gameState.guestChangeModifier = guestChangeModifier; - gameState.numGuestsInParkLastWeek = gameState.numGuestsInPark; + gameState.numGuestsInParkLastWeek = gameState.park.numGuestsInPark; // Update park rating, guests in park and current cash history constexpr auto ratingHistorySize = std::extent_v; HistoryPushRecord(gameState.park.RatingHistory, gameState.park.Rating); - constexpr auto numGuestsHistorySize = std::extent_v; - HistoryPushRecord(gameState.guestsInParkHistory, gameState.numGuestsInPark); + constexpr auto numGuestsHistorySize = std::extent_v; + HistoryPushRecord(gameState.park.guestsInParkHistory, gameState.park.numGuestsInPark); - constexpr auto cashHistorySize = std::extent_v; + constexpr auto cashHistorySize = std::extent_v; HistoryPushRecord(gameState.park.cashHistory, FinanceGetCurrentCash() - gameState.bankLoan); // Update weekly profit history diff --git a/src/openrct2/world/ParkData.h b/src/openrct2/world/ParkData.h index 7fd2a9e8d9..8b53dbce0f 100644 --- a/src/openrct2/world/ParkData.h +++ b/src/openrct2/world/ParkData.h @@ -77,5 +77,8 @@ namespace OpenRCT2::Park money64 currentExpenditure; money64 companyValue; + + uint32_t guestsInParkHistory[kGuestsInParkHistorySize]; + uint32_t numGuestsInPark; }; } // namespace OpenRCT2::Park