From 0cae5feba952a8084fe6abee197b67c4ac21a700 Mon Sep 17 00:00:00 2001 From: Hyper <34012267+hyperbx@users.noreply.github.com> Date: Thu, 17 Oct 2024 21:59:36 +0100 Subject: [PATCH] Display correct game logo for Japanese --- UnleashedRecomp/game.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/UnleashedRecomp/game.cpp b/UnleashedRecomp/game.cpp index acdd2f0..6acd3d9 100644 --- a/UnleashedRecomp/game.cpp +++ b/UnleashedRecomp/game.cpp @@ -71,3 +71,18 @@ void CSDOffsetMidAsmHook(PPCRegister& f1, PPCRegister& f2) *(be*)g_memory.Translate(0x8339C5D4) = ((1280.0f / newAspectRatio) - 720.0f) / 2.0f / 720.0f; } } + +/* Hook function that gets the game region + and force result to zero for Japanese + to display the correct logos. */ +PPC_FUNC_IMPL(__imp__sub_825197C0); +PPC_FUNC(sub_825197C0) +{ + if (Config::Language == ELanguage_Japanese) + { + ctx.r3.u64 = 0; + return; + } + + __imp__sub_825197C0(ctx, base); +}