diff --git a/projects/Core/api/system/save_files.cpp b/projects/Core/api/system/save_files.cpp index ec652f23b5..e69b9f747b 100644 --- a/projects/Core/api/system/save_files.cpp +++ b/projects/Core/api/system/save_files.cpp @@ -14,9 +14,12 @@ namespace core::api::save_files { } auto save_info = SaveGameController::GetSaveFileInfo(game::save_controller(), slot_index, backup_index); - auto path = save_info->fields.m_FullBackupSaveFilePath; - auto path_str = il2cpp::convert_csstring(path); - return System::IO::File::ReadAllBytes(path); + + return System::IO::File::ReadAllBytes( + backup_index >= 0 + ? save_info->fields.m_FullBackupSaveFilePath + : save_info->fields.m_FullSaveFilePath + ); } std::vector get_bytes(int slot_index, int backup_index) { diff --git a/projects/Randomizer/ui/main_menu_seed_info.cpp b/projects/Randomizer/ui/main_menu_seed_info.cpp index 6b5d77244e..95e7fc89c0 100644 --- a/projects/Randomizer/ui/main_menu_seed_info.cpp +++ b/projects/Randomizer/ui/main_menu_seed_info.cpp @@ -435,7 +435,7 @@ namespace randomizer::main_menu_seed_info { auto seed_meta_data = std::make_shared(); const auto read_slots = core::save_meta::read_save_meta_slots_from_byte_array( - core::api::save_files::get_byte_array(index, -1), + core::api::save_files::get_byte_array(index), { {SaveMetaSlot::SeedMetaData, seed_meta_data} }