mirror of
https://github.com/CookiePLMonster/SilentPatch.git
synced 2024-11-25 14:52:30 +01:00
Timers now work properly in III/VC (Billie Jean plays again!)
This commit is contained in:
parent
c19ae65d46
commit
9bfbcd83f0
@ -96,7 +96,7 @@ void CTimer::Resume()
|
||||
// MVL fix
|
||||
InitTimerFunc();
|
||||
#endif
|
||||
oldTime = timerFunction() - suspendTime;
|
||||
oldTime += timerFunction() - suspendTime;
|
||||
}
|
||||
}
|
||||
|
||||
@ -116,17 +116,6 @@ unsigned int CTimer::GetCyclesPerMillisecond()
|
||||
|
||||
void CTimer::Update()
|
||||
{
|
||||
#ifdef SILENTPATCH_VC_VER
|
||||
// CTimer::Initialise workaround
|
||||
static bool bIntialisedIt = false;
|
||||
|
||||
if ( !bIntialisedIt )
|
||||
{
|
||||
Initialise();
|
||||
bIntialisedIt = true;
|
||||
}
|
||||
#endif
|
||||
|
||||
*m_snPreviousTimeInMilliseconds = *m_snTimeInMilliseconds;
|
||||
cyclesPreviousTime = cyclesTime;
|
||||
|
||||
|
@ -290,6 +290,8 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
|
||||
else if(*(DWORD*)0x667C40 == 0x53E58955) Patch_VC_11();
|
||||
else if (*(DWORD*)0x666BA0 == 0x53E58955) Patch_VC_Steam();
|
||||
else return FALSE;
|
||||
|
||||
CTimer::Initialise();
|
||||
}
|
||||
return TRUE;
|
||||
}
|
Loading…
Reference in New Issue
Block a user