- allow the compact and pretty writers for JSON to coexist by wrapping the whole stuff into another class that calls the proper one as needed. Due to the implementation it is not possible to decide at run time how this should behave so there have to be two different objects for either mode.

- savegame code handles new format.
This commit is contained in:
Christoph Oelckers 2016-09-21 21:57:24 +02:00
commit 88c27e2cc0
12 changed files with 413 additions and 282 deletions

View file

@ -94,7 +94,7 @@
void STAT_StartNewGame(const char *lev);
void STAT_ChangeLevel(const char *newl);
EXTERN_CVAR(Bool, save_formatted)
EXTERN_CVAR (Float, sv_gravity)
EXTERN_CVAR (Float, sv_aircontrol)
EXTERN_CVAR (Int, disableautosave)
@ -1489,7 +1489,7 @@ void G_SnapshotLevel ()
{
FSerializer arc;
if (arc.OpenWriter())
if (arc.OpenWriter(save_formatted))
{
SaveVersion = SAVEVER;
G_SerializeLevel(arc, false);