From 579c343d1361801c936eedae50d956018a7d83f4 Mon Sep 17 00:00:00 2001 From: lukaslw Date: Sat, 8 Mar 2014 00:31:27 +0100 Subject: DRACI: Saving improvements (item in hand and hero position). --- engines/draci/saveload.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'engines/draci/saveload.cpp') diff --git a/engines/draci/saveload.cpp b/engines/draci/saveload.cpp index 31ac63b791..3e7f8651c1 100644 --- a/engines/draci/saveload.cpp +++ b/engines/draci/saveload.cpp @@ -45,7 +45,8 @@ bool readSavegameHeader(Common::InSaveFile *in, DraciSavegameHeader &header) { return false; header.version = in->readByte(); - if (header.version != DRACI_SAVEGAME_VERSION) + // Version 1 is compatible with Version 2 + if (header.version > DRACI_SAVEGAME_VERSION) return false; // Read in the string @@ -106,7 +107,7 @@ Common::Error saveSavegameData(int saveGameIdx, const Common::String &saveName, } else { // Create the remainder of the savegame Common::Serializer s(NULL, f); - vm._game->DoSync(s); + vm._game->DoSync(s, header.version); f->finalize(); delete f; @@ -140,7 +141,7 @@ Common::Error loadSavegameData(int saveGameIdx, DraciEngine *vm) { // Synchronise the remaining data of the savegame Common::Serializer s(f, NULL); - vm->_game->DoSync(s); + vm->_game->DoSync(s, header.version); delete f; // Post-processing -- cgit v1.2.3