6 const uint8_t* data,
size_t len) {
8 if (!data)
return state;
10 auto read = [&](uint16_t offset) -> uint8_t {
11 return (offset < len) ? data[offset] : 0;
47 return "Kydrog Complete";
49 return "Farore Rescued";
51 return "Unknown (" + std::to_string(
game_state) +
")";
56 switch (dungeon_number) {
58 return "D1 Mushroom Grotto";
60 return "D2 Tail Palace";
62 return "D3 Kalyxo Castle";
64 return "D4 Zora Temple";
66 return "D5 Glacia Estate";
68 return "D6 Goron Mines";
70 return "D7 Dragon Ship";
72 return "Unknown Dungeon";
78 switch (dungeon_number) {
Oracle of Secrets game progression state parsed from SRAM.
static constexpr uint8_t kCrystalD3
static constexpr uint8_t kCrystalD5
static constexpr uint16_t kSideQuestOffset
static uint8_t GetCrystalMask(int dungeon_number)
Get the crystal bitmask for a dungeon number (1-7).
static constexpr uint16_t kPendantOffset
static OracleProgressionState ParseFromSRAM(const uint8_t *data, size_t len)
Parse progression state from raw SRAM data.
static constexpr uint16_t kGameStateOffset
int GetCrystalCount() const
Count completed dungeons using popcount on crystal bitfield.
static constexpr uint8_t kCrystalD1
static constexpr uint16_t kOosProgOffset
bool IsDungeonComplete(int dungeon_number) const
Check if a specific dungeon is complete.
static constexpr uint8_t kCrystalD6
static constexpr uint8_t kCrystalD2
static std::string GetDungeonName(int dungeon_number)
Get the dungeon name for a dungeon number (1-7).
static constexpr uint16_t kOosProg2Offset
std::string GetGameStateName() const
Get human-readable name for the current game state.
static constexpr uint16_t kCrystalOffset
static constexpr uint8_t kCrystalD7
static constexpr uint8_t kCrystalD4