Add Pause to Dirty Drivin
This commit is contained in:
parent
429ec65f78
commit
a3b3617078
@ -4,7 +4,7 @@
|
||||
#include "Functions/Global.h"
|
||||
#include "Utility/Helper.h"
|
||||
|
||||
bool PauseGameFixInit;
|
||||
static bool PauseGameFixInit;
|
||||
static DWORD TimerValue;
|
||||
|
||||
void PauseGameFixes(Helpers* helpers)
|
||||
@ -18,4 +18,16 @@ void PauseGameFixes(Helpers* helpers)
|
||||
}
|
||||
helpers->WriteIntPtr(0x9C4A07, TimerValue, false);
|
||||
}
|
||||
|
||||
if (GameDetect::currentGame == GameID::DirtyDrivin)
|
||||
helpers->WriteByte(0x99D894, 0x01, false);
|
||||
}
|
||||
|
||||
void ResetPauseGameFixes(Helpers* helpers)
|
||||
{
|
||||
if (GameDetect::currentGame == GameID::SR3)
|
||||
PauseGameFixInit = false;
|
||||
|
||||
if (GameDetect::currentGame == GameID::DirtyDrivin)
|
||||
helpers->WriteByte(0x99D894, 0x00, false);
|
||||
}
|
@ -28,8 +28,9 @@ static char PauseKeyChar[256];
|
||||
static char ExitKeyChar[256];
|
||||
static int PauseKeyValue;
|
||||
static int ExitKeyValue;
|
||||
extern bool PauseGameFixInit;
|
||||
|
||||
extern void PauseGameFixes(Helpers* helpers);
|
||||
extern void ResetPauseGameFixes(Helpers* helpers);
|
||||
|
||||
void *__cdecl memcpy_0(void *a1, const void *a2, size_t a3)
|
||||
{
|
||||
@ -125,7 +126,7 @@ static BOOL SuspendProcess(DWORD ProcessId, bool Suspend)
|
||||
if (SuspendPressedOff)
|
||||
{
|
||||
SuspendPressedOff = false;
|
||||
PauseGameFixInit = false;
|
||||
ResetPauseGameFixes(0);
|
||||
waveOutSetVolume(NULL, dwVolume);
|
||||
SuspendProcess(ProcessID, false);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user