diff options
author | D G Turner | 2013-12-06 22:55:03 +0000 |
---|---|---|
committer | D G Turner | 2013-12-06 22:55:03 +0000 |
commit | 7432a33137b0871bd1b8b80b63d4494b293b39b4 (patch) | |
tree | 88a71de65efcfc222dbebaec869189de925618e0 /engines/drascula | |
parent | 189d8048f3007f677eea538bb7d7cc4c525a3424 (diff) | |
download | scummvm-rg350-7432a33137b0871bd1b8b80b63d4494b293b39b4.tar.gz scummvm-rg350-7432a33137b0871bd1b8b80b63d4494b293b39b4.tar.bz2 scummvm-rg350-7432a33137b0871bd1b8b80b63d4494b293b39b4.zip |
DRASCULA: Hookup up debug console correctly.
This now opens correctly on CTRL-d keystroke.
Diffstat (limited to 'engines/drascula')
-rw-r--r-- | engines/drascula/drascula.cpp | 5 | ||||
-rw-r--r-- | engines/drascula/drascula.h | 9 |
2 files changed, 10 insertions, 4 deletions
diff --git a/engines/drascula/drascula.cpp b/engines/drascula/drascula.cpp index 163f0077fc..14cb4be5a0 100644 --- a/engines/drascula/drascula.cpp +++ b/engines/drascula/drascula.cpp @@ -864,6 +864,11 @@ void DrasculaEngine::updateEvents() { #endif switch (event.type) { case Common::EVENT_KEYDOWN: + if (event.kbd.keycode == Common::KEYCODE_d && event.kbd.hasFlags(Common::KBD_CTRL)) { + // Start the debugger + getDebugger()->attach(); + getDebugger()->onFrame(); + } addKeyToBuffer(event.kbd); break; case Common::EVENT_KEYUP: diff --git a/engines/drascula/drascula.h b/engines/drascula/drascula.h index 944191b5fb..53fce9c212 100644 --- a/engines/drascula/drascula.h +++ b/engines/drascula/drascula.h @@ -38,6 +38,8 @@ #include "engines/savestate.h" +#include "drascula/console.h" + #include "audio/mixer.h" #include "engines/engine.h" @@ -313,8 +315,6 @@ static const int interf_y[] = { 51, 51, 51, 51, 83, 83, 83 }; struct RoomHandlers; -class Console; - class DrasculaEngine : public Engine { protected: // Engine APIs @@ -724,11 +724,12 @@ public: void update_62_pre(); void update_102(); + Console *_console; + GUI::Debugger *getDebugger() { return _console; } + private: int _lang; - Console *_console; - CharInfo *_charMap; int _charMapSize; |