aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/mads/debugger.cpp10
-rw-r--r--engines/mads/debugger.h1
2 files changed, 11 insertions, 0 deletions
diff --git a/engines/mads/debugger.cpp b/engines/mads/debugger.cpp
index 58bf8388e4..276340f240 100644
--- a/engines/mads/debugger.cpp
+++ b/engines/mads/debugger.cpp
@@ -37,6 +37,7 @@ Debugger::Debugger(MADSEngine *vm) : GUI::Debugger(), _vm(vm) {
DCmd_Register("play_sound", WRAP_METHOD(Debugger, Cmd_PlaySound));
DCmd_Register("show_codes", WRAP_METHOD(Debugger, Cmd_ShowCodes));
DCmd_Register("dump_file", WRAP_METHOD(Debugger, Cmd_DumpFile));
+ DCmd_Register("show_quote", WRAP_METHOD(Debugger, Cmd_ShowQuote));
}
static int strToInt(const char *s) {
@@ -168,4 +169,13 @@ bool Debugger::Cmd_DumpFile(int argc, const char **argv) {
return true;
}
+bool Debugger::Cmd_ShowQuote(int argc, const char **argv) {
+ if (argc != 2)
+ DebugPrintf("Usage: %s <quote number>\n", argv[0]);
+ else
+ DebugPrintf("%s", _vm->_game->getQuote(strToInt(argv[1])).c_str());
+
+ return true;
+}
+
} // End of namespace MADS
diff --git a/engines/mads/debugger.h b/engines/mads/debugger.h
index de450b1446..b2b0949923 100644
--- a/engines/mads/debugger.h
+++ b/engines/mads/debugger.h
@@ -41,6 +41,7 @@ protected:
bool Cmd_PlaySound(int argc, const char **argv);
bool Cmd_ShowCodes(int argc, const char **argv);
bool Cmd_DumpFile(int argc, const char **argv);
+ bool Cmd_ShowQuote(int argc, const char **argv);
public:
bool _showMousePos;
public: