mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-25 05:21:02 +00:00
Fixed freeze after saving game when cl_waitforsave CVAR set to false
Restored assertions that help to spot incorrect usage of I_FreezeTime() function https://forum.zdoom.org/viewtopic.php?t=59672
This commit is contained in:
parent
d0ec6ef1d4
commit
ac47166894
2 changed files with 5 additions and 1 deletions
|
@ -2388,6 +2388,8 @@ void G_DoSaveGame (bool okForQuicksave, FString filename, const char *descriptio
|
|||
level.info->Snapshot.Clean();
|
||||
|
||||
insave = false;
|
||||
|
||||
if (cl_waitforsave)
|
||||
I_FreezeTime(false);
|
||||
}
|
||||
|
||||
|
|
|
@ -187,10 +187,12 @@ void I_FreezeTime(bool frozen)
|
|||
{
|
||||
if (frozen)
|
||||
{
|
||||
assert(FreezeTime == 0);
|
||||
FreezeTime = GetClockTimeNS();
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(FreezeTime != 0);
|
||||
FirstFrameStartTime += GetClockTimeNS() - FreezeTime;
|
||||
FreezeTime = 0;
|
||||
I_SetFrameTime();
|
||||
|
|
Loading…
Reference in a new issue