From 786f7db38fa8772753cabb493063e785511688d9 Mon Sep 17 00:00:00 2001 From: InspirationByte Date: Sun, 6 Feb 2022 11:55:50 +0300 Subject: [PATCH 1/2] - revert one of bug fixes to original code and fix cop loosing player issue --- src_rebuild/Game/C/cop_ai.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src_rebuild/Game/C/cop_ai.c b/src_rebuild/Game/C/cop_ai.c index ad14cd86..e4b66db1 100644 --- a/src_rebuild/Game/C/cop_ai.c +++ b/src_rebuild/Game/C/cop_ai.c @@ -1189,8 +1189,7 @@ void ControlCops(void) copsWereInPursuit = 0; - if (CopsCanSeePlayer && OutOfSightCount < 256 || // [A] was player_position_known. Resolves speech in some missions - player_position_known > 1 && GameType == GAME_GETAWAY) + if (player_position_known > 0) { if (*playerFelony > FELONY_PURSUIT_MIN_VALUE) copsWereInPursuit = 1; From adeeb77cf2d870a53397de1313da18d2506b2978 Mon Sep 17 00:00:00 2001 From: InspirationByte Date: Mon, 7 Feb 2022 20:51:48 +0300 Subject: [PATCH 2/2] - simplify ifdefs in main --- src_rebuild/Game/C/main.c | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) diff --git a/src_rebuild/Game/C/main.c b/src_rebuild/Game/C/main.c index e0d0f9d8..54a3ab61 100644 --- a/src_rebuild/Game/C/main.c +++ b/src_rebuild/Game/C/main.c @@ -1546,9 +1546,7 @@ void CheckForPause(void) } } -#ifdef PSX int gMultiStep = 0; -#endif // [D] [T] void State_GameLoop(void* param) @@ -1568,17 +1566,16 @@ void State_GameLoop(void* param) UpdatePadData(); CheckForPause(); + // moved from StepGame + if (FrameCnt == 5) + SetDispMask(1); + #ifdef PSX static int lastTime32Hz = 0; int curTime = clock_realTime.time32Hz; int numFrames = curTime - lastTime32Hz; - // moved from StepGame - if (FrameCnt == 5) - SetDispMask(1); - - // game makes 7 frames if (FastForward) cnt = 7; else @@ -1598,25 +1595,14 @@ void State_GameLoop(void* param) StepGame(); } - - DrawGame(); #else - // moved from StepGame - if (FrameCnt == 5) - SetDispMask(1); - - // game makes 7 frames - if (FastForward) - cnt = 7; - else - cnt = 1; - + cnt = FastForward ? 7 : 1; while (--cnt >= 0) StepGame(); +#endif _CutRec_Draw(); DrawGame(); -#endif if (game_over) SetState(STATE_GAMECOMPLETE);