Skip to content

Commit ec0378a

Browse files
Pause replay on CRC mismatch (#876)
Signed-off-by: aliendroid1 <9aliquraishi9@gmail.com>
1 parent 1c117fa commit ec0378a

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

Generals/Code/GameEngine/Source/Common/Recorder.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1036,6 +1036,9 @@ void RecorderClass::handleCRCMessage(UnsignedInt newCRC, Int playerIndex, Bool f
10361036
// the mismatch first happened in case the NetCRCInterval is set to 1 during the game.
10371037
DEBUG_CRASH(("Replay has gone out of sync! All bets are off!\nInGame:%8.8X Replay:%8.8X\nFrame:%d",
10381038
playbackCRC, newCRC, TheGameLogic->getFrame()-m_crcInfo->GetQueueSize()-1));
1039+
1040+
// TheSuperHackers @tweak Pause the game on mismatch.
1041+
TheGameLogic->setGamePaused(true);
10391042
}
10401043
return;
10411044
}

GeneralsMD/Code/GameEngine/Source/Common/Recorder.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1039,6 +1039,9 @@ void RecorderClass::handleCRCMessage(UnsignedInt newCRC, Int playerIndex, Bool f
10391039
// the mismatch first happened in case the NetCRCInterval is set to 1 during the game.
10401040
DEBUG_CRASH(("Replay has gone out of sync! All bets are off!\nInGame:%8.8X Replay:%8.8X\nFrame:%d",
10411041
playbackCRC, newCRC, TheGameLogic->getFrame()-m_crcInfo->GetQueueSize()-1));
1042+
1043+
// TheSuperHackers @tweak Pause the game on mismatch.
1044+
TheGameLogic->setGamePaused(true);
10421045
}
10431046
return;
10441047
}

0 commit comments

Comments
 (0)