aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTravis Howell2006-02-04 23:51:25 +0000
committerTravis Howell2006-02-04 23:51:25 +0000
commitbdedc81c229793dadcf4f8e7201eeb586073c724 (patch)
treee8788bdfac63c1665296fe8c2cad535cbb1fd9ac
parent484f6d1ad95f438f7b8eb67b7c3d53a71eaf65b3 (diff)
downloadscummvm-rg350-bdedc81c229793dadcf4f8e7201eeb586073c724.tar.gz
scummvm-rg350-bdedc81c229793dadcf4f8e7201eeb586073c724.tar.bz2
scummvm-rg350-bdedc81c229793dadcf4f8e7201eeb586073c724.zip
Fix restarting Maniac NES.
svn-id: r20380
-rw-r--r--scumm/scumm.cpp18
1 files changed, 13 insertions, 5 deletions
diff --git a/scumm/scumm.cpp b/scumm/scumm.cpp
index c0e9d0acd2..b52a1c0464 100644
--- a/scumm/scumm.cpp
+++ b/scumm/scumm.cpp
@@ -2718,15 +2718,23 @@ void ScummEngine::restart() {
for (i = 0; i < _numGlobalObjects; i++)
clearOwnerOf(i);
- // Reinit things
- allocateArrays(); // Reallocate arrays
- readIndexFile(); // Reread index (reset objectstate etc)
- scummInit(); // Reinit scumm variables
+ // Reallocate arrays
+ allocateArrays();
+
+ // Reread index (reset objectstate etc)
+ readIndexFile();
+
+ // Reinit scumm variables
+ scummInit();
initScummVars();
+
if (_imuse) {
_imuse->setBase(res.address[rtSound]);
}
- _sound->setupSound(); // Reinit sound engine
+
+ // Reinit sound engine
+ if (_version >= 5)
+ _sound->setupSound();
// Re-run bootscript
int args[16];