1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-15 11:03:00 +01:00

Remove unused gSavedAge (#21410)

* Remove the unused SavedAge variable.
This commit is contained in:
Harry Hopkinson
2024-02-20 19:58:46 +00:00
committed by GitHub
parent d8864e567c
commit b989ccbb20
7 changed files with 1 additions and 9 deletions

View File

@@ -369,7 +369,6 @@ void GameState::UpdateLogic()
NetworkFlush();
gameState.CurrentTicks++;
gSavedAge++;
#ifdef ENABLE_SCRIPTING
auto& hookEngine = GetContext()->GetScriptEngine().GetHookEngine();

View File

@@ -171,8 +171,6 @@ const std::list<EntityId>& GetEntityList(const EntityType id)
*/
void ResetAllEntities()
{
gSavedAge = 0;
// Free all associated Entity pointers prior to zeroing memory
for (int32_t i = 0; i < MAX_ENTITIES; ++i)
{

View File

@@ -988,7 +988,7 @@ namespace RCT2
char CustomStrings[Limits::MaxUserStrings][Limits::MaxUserStringLength];
uint32_t GameTicks1;
Ride Rides[Limits::MaxRidesInPark];
uint16_t SavedAge;
uint16_t SavedAge; // unused
int16_t SavedViewX;
int16_t SavedViewY;
uint8_t SavedViewZoom;

View File

@@ -440,7 +440,6 @@ namespace RCT2
ImportRides();
gSavedAge = _s6.SavedAge;
gSavedView = ScreenCoordsXY{ _s6.SavedViewX, _s6.SavedViewY };
gSavedViewZoom = ZoomLevel{ static_cast<int8_t>(_s6.SavedViewZoom) };
gSavedViewRotation = _s6.SavedViewRotation;

View File

@@ -69,7 +69,6 @@ const StringId ScenarioCategoryStringIds[SCENARIO_CATEGORY_COUNT] = {
std::string gScenarioSavePath;
bool gFirstTimeSaving = true;
uint16_t gSavedAge;
uint32_t gLastAutoSaveUpdate = 0;
bool gAllowEarlyCompletionInNetworkPlay;

View File

@@ -162,7 +162,6 @@ extern bool gAllowEarlyCompletionInNetworkPlay;
extern std::string gScenarioSavePath;
extern bool gFirstTimeSaving;
extern uint16_t gSavedAge;
extern uint32_t gLastAutoSaveUpdate;
extern std::string gScenarioFileName;

View File

@@ -184,8 +184,6 @@ void TitleScreen::Tick()
ContextUpdateMapTooltip();
WindowDispatchUpdateAll();
gSavedAge++;
ContextHandleInput();
gInUpdateCode = false;