Skip to content

Commit 0936460

Browse files
committed
Handle VoiceLanguage for CSB and SBK
Signed-off-by: Isaac Marovitz <isaacryu@icloud.com>
1 parent f7f076b commit 0936460

2 files changed

Lines changed: 15 additions & 0 deletions

File tree

MarathonRecomp/patches/misc_patches.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,3 +112,8 @@ void XmvPlayerLang(PPCRegister& r11)
112112
if (Config::VoiceLanguage == EVoiceLanguage::Japanese)
113113
r11.u32++;
114114
}
115+
116+
void CsbSbkLang(PPCRegister& r8)
117+
{
118+
r8.u32 = Config::VoiceLanguage == EVoiceLanguage::Japanese ? 0 : 1;
119+
}

MarathonRecompLib/config/Marathon.toml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,3 +224,13 @@ registers = ["f31"]
224224
name = "XmvPlayerLang"
225225
address = 0x8264D844
226226
registers = ["r11"]
227+
228+
[[midasm_hook]]
229+
name = "CsbSbkLang"
230+
address = 0x826124B0
231+
registers = ["r8"]
232+
233+
[[midasm_hook]]
234+
name = "CsbSbkLang"
235+
address = 0x826121BC
236+
registers = ["r8"]

0 commit comments

Comments
 (0)