mirror of
https://github.com/CookiePLMonster/SilentPatch.git
synced 2024-12-29 15:23:02 +05:00
III 1.1 mouse sens fix backported to 1.0
This commit is contained in:
parent
9e0d878a46
commit
c587821c63
1 changed files with 20 additions and 0 deletions
|
@ -219,6 +219,21 @@ void __declspec(naked) SubtitlesShadowFix()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void __declspec(naked) III_SensResetFix()
|
||||||
|
{
|
||||||
|
_asm
|
||||||
|
{
|
||||||
|
mov ecx, 3A76h
|
||||||
|
mov edi, ebp
|
||||||
|
fld dword ptr [ebp+194h]
|
||||||
|
fld dword ptr [ebp+198h]
|
||||||
|
rep stosd
|
||||||
|
fstp dword ptr [ebp+198h]
|
||||||
|
fstp dword ptr [ebp+194h]
|
||||||
|
retn
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
char** const ppUserFilesDir = AddressByVersion<char**>(0x580C16, 0x580F66, 0x580E66);
|
char** const ppUserFilesDir = AddressByVersion<char**>(0x580C16, 0x580F66, 0x580E66);
|
||||||
|
|
||||||
char* GetMyDocumentsPath()
|
char* GetMyDocumentsPath()
|
||||||
|
@ -365,6 +380,11 @@ void Patch_III_10(const RECT& desktop)
|
||||||
// BOOOOORING fixed
|
// BOOOOORING fixed
|
||||||
Patch<BYTE>(0x4925D7, 10);
|
Patch<BYTE>(0x4925D7, 10);
|
||||||
|
|
||||||
|
// 1.1 mouse sensitivity not resetting fix
|
||||||
|
Patch<WORD>(0x46BE81, 0x12EB);
|
||||||
|
Nop(0x46BAD6, 4);
|
||||||
|
InjectHook(0x46BADA, III_SensResetFix, PATCH_CALL);
|
||||||
|
|
||||||
// (Hopefully) more precise frame limiter
|
// (Hopefully) more precise frame limiter
|
||||||
int pAddress = 0x582EFD;
|
int pAddress = 0x582EFD;
|
||||||
RsEventHandler = (void(*)(int,void*))(*(int*)(pAddress+1) + pAddress + 5);
|
RsEventHandler = (void(*)(int,void*))(*(int*)(pAddress+1) + pAddress + 5);
|
||||||
|
|
Loading…
Reference in a new issue