diff options
author | Gregory Montoir | 2003-12-26 12:58:27 +0000 |
---|---|---|
committer | Gregory Montoir | 2003-12-26 12:58:27 +0000 |
commit | ffbfe8922a3cfa2d2750fca3a2cb2d953fd1e4ca (patch) | |
tree | e75942537560cbf1939534597c120258ceba69cb /queen/debug.h | |
parent | a45e92efed3715b3bb0b1191b718207b191ab1ae (diff) | |
download | scummvm-rg350-ffbfe8922a3cfa2d2750fca3a2cb2d953fd1e4ca.tar.gz scummvm-rg350-ffbfe8922a3cfa2d2750fca3a2cb2d953fd1e4ca.tar.bz2 scummvm-rg350-ffbfe8922a3cfa2d2750fca3a2cb2d953fd1e4ca.zip |
new debugging code, using Common::Debugger
svn-id: r11940
Diffstat (limited to 'queen/debug.h')
-rw-r--r-- | queen/debug.h | 49 |
1 files changed, 15 insertions, 34 deletions
diff --git a/queen/debug.h b/queen/debug.h index 25cf02529d..6dd0f71cbb 100644 --- a/queen/debug.h +++ b/queen/debug.h @@ -22,57 +22,38 @@ #ifndef QUEENDEBUG_H #define QUEENDEBUG_H -#include "common/util.h" +#include "common/debugger.h" namespace Queen { class QueenEngine; -class Debug { +class Debugger : public Common::Debugger<Debugger> { public: - typedef void (Debug::*DebugFunc)(); - Debug(QueenEngine *vm); + Debugger(QueenEngine *vm); - void registerStub(const char *password, DebugFunc debugFunc); + bool _drawAreas; - void update(int c); +protected: - void jumpToRoom(); - void toggleFastMode(); - void printInfo(); - void toggleAreasDrawing(); - void changeGameState(); - void printGameState(); - void giveAllItems(); - - static void digitKeyPressed(void *refCon, int key); - - struct DebugStub { - const char *password; - DebugFunc function; - }; - - enum { - MAX_STUB = 5 - }; + virtual void preEnter(); + virtual void postEnter(); + bool Cmd_Exit(int argc, const char **argv); + bool Cmd_Help(int argc, const char **argv); + bool Cmd_Areas(int argc, const char **argv); + bool Cmd_Asm(int argc, const char **argv); + bool Cmd_GameState(int argc, const char **argv); + bool Cmd_Info(int argc, const char **argv); + bool Cmd_Items(int argc, const char **argv); + bool Cmd_Room(int argc, const char **argv); private: - char _password[16]; - uint _passwordCharCount; - - char _digitText[50]; - uint _digitTextCount; - - DebugStub _stub[MAX_STUB]; - uint _stubCount; - QueenEngine *_vm; }; - } // End of namespace Queen #endif |