diff options
| author | Johannes Schickel | 2006-01-12 14:53:23 +0000 |
|---|---|---|
| committer | Johannes Schickel | 2006-01-12 14:53:23 +0000 |
| commit | f0544b2e6bfbb8cf51c44215e8dafd377d7cfa05 (patch) | |
| tree | a7456fdbf6015f919b44a10916e8c261814d49bd /kyra/saveload.cpp | |
| parent | 2416254e494d93b52009548f940f7ca28bc4db6d (diff) | |
| download | scummvm-rg350-f0544b2e6bfbb8cf51c44215e8dafd377d7cfa05.tar.gz scummvm-rg350-f0544b2e6bfbb8cf51c44215e8dafd377d7cfa05.tar.bz2 scummvm-rg350-f0544b2e6bfbb8cf51c44215e8dafd377d7cfa05.zip | |
Fixed sound while loading games and fixed bug # 1403370.
svn-id: r19989
Diffstat (limited to 'kyra/saveload.cpp')
| -rw-r--r-- | kyra/saveload.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/kyra/saveload.cpp b/kyra/saveload.cpp index a46f3d302c..a396658660 100644 --- a/kyra/saveload.cpp +++ b/kyra/saveload.cpp @@ -27,7 +27,7 @@ #include "common/savefile.h" #include "common/system.h" -#define CURRENT_VERSION 2 +#define CURRENT_VERSION 3 namespace Kyra { void KyraEngine::loadGame(const char *fileName) { @@ -167,6 +167,11 @@ void KyraEngine::loadGame(const char *fileName) { _roomTable[sceneId].needInit[i] = in->readByte(); } } + if (version >= 3) { + _lastMusicCommand = in->readSint16BE(); + if (_lastMusicCommand != -1) + snd_playWanderScoreViaMap(_lastMusicCommand, 1); + } if (queryGameFlag(0x2D)) { loadMainScreen(8); @@ -297,6 +302,8 @@ void KyraEngine::saveGame(const char *fileName, const char *saveName) { } // room table terminator out->writeUint16BE(0xFFFF); + + out->writeSint16BE(_lastMusicCommand); out->flush(); |
