aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--common/savefile.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/common/savefile.cpp b/common/savefile.cpp
index 1e2725f98f..01185b6527 100644
--- a/common/savefile.cpp
+++ b/common/savefile.cpp
@@ -25,6 +25,10 @@
// FIXME HACK
+// Enable this to activate transparent zlib compression of all savegames
+// Note that doing that makes ScummVM produce savegames which can't trivially
+// be read by non-zlib enabled versions. However, one can always decompress
+// such a savegame by using gzip, so this shouldn't be a bad problem.
//#define USE_ZLIB
@@ -184,5 +188,9 @@ void SaveFileManager::join_paths(const char *filename, const char *directory,
}
SaveFile *SaveFileManager::makeSaveFile(const char *filename, bool saveOrLoad) {
+#ifdef USE_ZLIB
+ return new GzipSaveFile(filename, saveOrLoad);
+#else
return new StdioSaveFile(filename, saveOrLoad);
+#endif
}