From e8b2c502d409ede386fd8dbd7a6b15e48fba4a45 Mon Sep 17 00:00:00 2001 From: Phillip Stephens Date: Tue, 11 Oct 2022 10:12:00 -0700 Subject: [PATCH] Match CMemoryCardDriver::GetGameFileStateInfo Former-commit-id: eb3be0bc36361ff5efb01d9d576f51259443768b --- src/MetroidPrime/CMemoryCardDriver.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/MetroidPrime/CMemoryCardDriver.cpp b/src/MetroidPrime/CMemoryCardDriver.cpp index 3835bb96..65433161 100644 --- a/src/MetroidPrime/CMemoryCardDriver.cpp +++ b/src/MetroidPrime/CMemoryCardDriver.cpp @@ -794,8 +794,11 @@ void SGameFileSlot::InitializeFromGameState() { void SGameFileSlot::LoadGameState(int) {} -const CGameState::GameFileStateInfo* CMemoryCardDriver::GetGameFileStateInfo(int) { - return nullptr; +const CGameState::GameFileStateInfo* CMemoryCardDriver::GetGameFileStateInfo(int saveIdx) { + if (xe4_fileSlots[saveIdx].null()) { + return nullptr; + } + return &xe4_fileSlots[saveIdx]->x944_fileInfo; }; bool CMemoryCardDriver::GetCardFreeBytes() {