aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Montoir2006-05-29 18:30:27 +0000
committerGregory Montoir2006-05-29 18:30:27 +0000
commit7ff20a70a5966bfb55a896604bb7f3461e9cd03d (patch)
tree7e6837b40aea4786b7c3e4d24a08a862a2ee3ab4
parentd6f1ba1540d60d374121244565a08a9c77670e5b (diff)
downloadscummvm-rg350-7ff20a70a5966bfb55a896604bb7f3461e9cd03d.tar.gz
scummvm-rg350-7ff20a70a5966bfb55a896604bb7f3461e9cd03d.tar.bz2
scummvm-rg350-7ff20a70a5966bfb55a896604bb7f3461e9cd03d.zip
The ScummDebugger object needs to be created after _numVariables has been set. This is apparently only done in in readMAXS() which is called by readIndexFile(). Moved the call to the object constructor in the init() method. This fixes the 'scumm_vars' debugger command.
svn-id: r22755
-rw-r--r--engines/scumm/scumm.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/engines/scumm/scumm.cpp b/engines/scumm/scumm.cpp
index 8ed72f0a93..6f5e0f0317 100644
--- a/engines/scumm/scumm.cpp
+++ b/engines/scumm/scumm.cpp
@@ -966,6 +966,9 @@ int ScummEngine::init() {
readIndexFile();
+ // Create the debugger now that _numVariables has been set
+ _debugger = new ScummDebugger(this);
+
resetScumm();
resetScummVars();
@@ -1082,10 +1085,6 @@ void ScummEngine::setupScumm() {
#if (defined(PALMOS_ARM) || defined(PALMOS_DEBUG) || defined(__GP32__))
Graphics::initfonts();
#endif
-
- // Create debugger
- if (!_debugger)
- _debugger = new ScummDebugger(this);
}
void ScummEngine::setupCharsetRenderer() {