diff --git a/MarathonRecomp/patches/fps_patches.cpp b/MarathonRecomp/patches/fps_patches.cpp index 5067635d3..251ce4a5f 100644 --- a/MarathonRecomp/patches/fps_patches.cpp +++ b/MarathonRecomp/patches/fps_patches.cpp @@ -12,3 +12,9 @@ PPC_FUNC(sub_82587AA8) __imp__sub_82587AA8(ctx, base); } + +void PostureControlRotationSpeedFix(PPCRegister& c_rotation_speed, PPCRegister& stack) +{ + double deltaTime = *(be*)g_memory.Translate(stack.u32 + 0x200); + c_rotation_speed.f64 = (c_rotation_speed.f64 * (60.0f * deltaTime)); +} diff --git a/MarathonRecompLib/config/Marathon.toml b/MarathonRecompLib/config/Marathon.toml index d544183d9..bef3b84b4 100644 --- a/MarathonRecompLib/config/Marathon.toml +++ b/MarathonRecompLib/config/Marathon.toml @@ -204,3 +204,8 @@ registers = ["r26"] name = "DisableRadialBlur" address = 0x82653834 jump_address_on_true = 0x82653840 + +[[midasm_hook]] +name = "PostureControlRotationSpeedFix" +address = 0x82201C6C +registers = ["f1", "r1"]