mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 07:12:02 +00:00
Merge branch 'waitforsave' of https://github.com/Edward850/zdoom
This commit is contained in:
commit
b2a06f6ccd
1 changed files with 6 additions and 0 deletions
|
@ -116,6 +116,7 @@ CVAR (Bool, chasedemo, false, 0);
|
||||||
CVAR (Bool, storesavepic, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
CVAR (Bool, storesavepic, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
||||||
CVAR (Bool, longsavemessages, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
CVAR (Bool, longsavemessages, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
||||||
CVAR (String, save_dir, "", CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
CVAR (String, save_dir, "", CVAR_ARCHIVE|CVAR_GLOBALCONFIG);
|
||||||
|
CVAR (Bool, cl_waitforsave, true, CVAR_ARCHIVE | CVAR_GLOBALCONFIG);
|
||||||
EXTERN_CVAR (Float, con_midtime);
|
EXTERN_CVAR (Float, con_midtime);
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
@ -2147,6 +2148,9 @@ void G_DoSaveGame (bool okForQuicksave, FString filename, const char *descriptio
|
||||||
filename = G_BuildSaveName ("demosave.zds", -1);
|
filename = G_BuildSaveName ("demosave.zds", -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (cl_waitforsave)
|
||||||
|
I_FreezeTime(true);
|
||||||
|
|
||||||
insave = true;
|
insave = true;
|
||||||
G_SnapshotLevel ();
|
G_SnapshotLevel ();
|
||||||
|
|
||||||
|
@ -2156,6 +2160,7 @@ void G_DoSaveGame (bool okForQuicksave, FString filename, const char *descriptio
|
||||||
{
|
{
|
||||||
Printf ("Could not create savegame '%s'\n", filename.GetChars());
|
Printf ("Could not create savegame '%s'\n", filename.GetChars());
|
||||||
insave = false;
|
insave = false;
|
||||||
|
I_FreezeTime(false);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2232,6 +2237,7 @@ void G_DoSaveGame (bool okForQuicksave, FString filename, const char *descriptio
|
||||||
}
|
}
|
||||||
|
|
||||||
insave = false;
|
insave = false;
|
||||||
|
I_FreezeTime(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue