Files
isaac-port/src/game_state.cpp
T
shweetandClaude Opus 5.5 addd027977 Curation round 6: boot finished, the run starts; HUD, pause screen, minimap, preloads, floor generation
Six agents took over OnlineEmotes (emote wheel), OnlineStatsScreen's deeds, VictoryRunPrompt, RevivePlayerMenu, HUD,
PauseScreen, Minimap, PreloadManager, ProceduralItemManager, Game::LoadBossRushXml, GameState's loading, the menu loose
ends, Manager::StartNewGame, LevelGenerator and Level (Game now derives from Level). Integration: completion_widget.h
breaks an include loop, call sites moved to the new APIs. --mute (main.cpp) keeps the mixer running at zero gain.
build/isaac reaches the main menu by itself (input skips the intro); under gdb, picking a character calls
StartNewGame and stops at Game::Start. 1611 functions taken over, boot path 287/615.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-20 04:09:22 -05:00

32 lines
1.2 KiB
C++

#include "game_state.h"
#include "log.h"
#include "platform.h"
#include <cstdio>
// 009c79a0 Empties the saved run and drops both availabilities, keeping the files it is saved to.
void GameState::Clear()
{
*this = {.rerunPath = std::move(rerunPath), .savePath = std::move(savePath)};
}
// 009c8350 Removes the saved run's file, warning when there is none named, and empties the run.
void GameState::Delete()
{
if (savePath.empty()) log_printf(LOG_INFO, "[warn] GameState::Delete: no filename specified.\n");
std::remove(savePath.c_str());
Clear();
}
// 009c8410 Removes the rerun's file, keeping the run.
// The original warns on an empty save file name here too, not on the rerun's.
void GameState::DeleteRerun()
{
if (savePath.empty()) log_printf(LOG_INFO, "[warn] GameState::DeleteRerun: no filename specified.\n");
std::remove(rerunPath.c_str());
}
// Not reconstructed yet: each stops the game where it is reached.
// Netplay is offline, so read always reads a run as this machine's own (the original's isLocalRun).
bool GameState::read(std::span<const uint8_t>) { reconstruction_missing("GameState::read 009cc1a0"); }
bool GameState::read_rerun(std::span<const uint8_t>) { reconstruction_missing("GameState::read_rerun 009d7d50"); }