From 340c65ea33e3f151d93d903b69c72c791a6dad24 Mon Sep 17 00:00:00 2001 From: LittleCoaks Date: Mon, 4 Mar 2024 01:10:42 -0500 Subject: [PATCH] Fix non-mssb gecko codes Fix for non-mssb games not having working gecko codes --- Source/Core/Core/GeckoCode.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Core/Core/GeckoCode.cpp b/Source/Core/Core/GeckoCode.cpp index a28ff5e79179..df7d1354f430 100644 --- a/Source/Core/Core/GeckoCode.cpp +++ b/Source/Core/Core/GeckoCode.cpp @@ -171,7 +171,7 @@ static Installation InstallCodeHandlerLocked(const Core::CPUThreadGuard& guard) // Gets the free memory location for the current game. If game has not specified a auto free_memory_base_address = Core::getGameFreeMemory(); bool use_free_memory = Core::getGameFreeMemory().has_value(); - const u32 memory_base_address = use_free_memory ? free_memory_base_address.value() : INSTALLER_BASE_ADDRESS; + const u32 memory_base_address = use_free_memory ? free_memory_base_address.value() : INSTALLER_BASE_ADDRESS + static_cast(data.size()) - CODE_SIZE; // Install code handler for (u32 i = 0; i < data.size(); ++i) {