Skip to content

Commit 705ab6b

Browse files
authored
Player steering is now properly fixed for HFR (#118)
* POSTURE_STEER_FIX * Correction#1
1 parent 33499ab commit 705ab6b

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

MarathonRecomp/patches/fps_patches.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,9 @@ PPC_FUNC(sub_82587AA8)
1212

1313
__imp__sub_82587AA8(ctx, base);
1414
}
15+
16+
void PostureControlRotationSpeedFix(PPCRegister& c_rotation_speed, PPCRegister& stack)
17+
{
18+
double deltaTime = *(be<double>*)g_memory.Translate(stack.u32 + 0x200);
19+
c_rotation_speed.f64 = (c_rotation_speed.f64 * (60.0f * deltaTime));
20+
}

MarathonRecompLib/config/Marathon.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,3 +204,8 @@ registers = ["r26"]
204204
name = "DisableRadialBlur"
205205
address = 0x82653834
206206
jump_address_on_true = 0x82653840
207+
208+
[[midasm_hook]]
209+
name = "PostureControlRotationSpeedFix"
210+
address = 0x82201C6C
211+
registers = ["f1", "r1"]

0 commit comments

Comments
 (0)