diff --git a/SilentPatch/Timer.cpp b/SilentPatch/Timer.cpp index 5e90fa6..5127aa1 100644 --- a/SilentPatch/Timer.cpp +++ b/SilentPatch/Timer.cpp @@ -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; diff --git a/VCFix/SilentPatchVC.cpp b/VCFix/SilentPatchVC.cpp index 1975107..5fcbd67 100644 --- a/VCFix/SilentPatchVC.cpp +++ b/VCFix/SilentPatchVC.cpp @@ -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; } \ No newline at end of file