diff options
author | Eugene Sandulenko | 2019-12-01 14:45:03 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2019-12-01 16:29:54 +0100 |
commit | 4fbcc337af97560fdd648a28a6e4e7586f419684 (patch) | |
tree | b38b7b5ca4df58ebf719c335f6aa66980d4ff0af | |
parent | 89c1f2cfefd5017a92727337a31d339651275d3e (diff) | |
download | scummvm-rg350-4fbcc337af97560fdd648a28a6e4e7586f419684.tar.gz scummvm-rg350-4fbcc337af97560fdd648a28a6e4e7586f419684.tar.bz2 scummvm-rg350-4fbcc337af97560fdd648a28a6e4e7586f419684.zip |
DIRECTOR: LINGO: Improve debug output
-rw-r--r-- | engines/director/lingo/lingo.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/engines/director/lingo/lingo.cpp b/engines/director/lingo/lingo.cpp index d009893747..805bcb5f38 100644 --- a/engines/director/lingo/lingo.cpp +++ b/engines/director/lingo/lingo.cpp @@ -174,17 +174,19 @@ void Lingo::addCode(const char *code, ScriptType type, uint16 id) { parse(chunk.c_str()); if (debugChannelSet(3, kDebugLingoCompile)) { + debugC(2, kDebugLingoCompile, "<current code>"); uint pc = 0; while (pc < _currentScript->size()) { Common::String instr = decodeInstruction(_currentScript, pc, &pc); debugC(2, kDebugLingoCompile, "[%5d] %s", pc, instr.c_str()); } + debugC(2, kDebugLingoCompile, "<end code>"); } begin = end; } while ((end = findNextDefinition(begin + 1))); - debugC(1, kDebugLingoCompile, "Code chunk:\n#####\n%s\n#####", begin); + debugC(1, kDebugLingoCompile, "Last code chunk:\n#####\n%s\n#####", begin); parse(begin); code1(STOP); @@ -200,11 +202,13 @@ void Lingo::addCode(const char *code, ScriptType type, uint16 id) { if (_currentScript->size() && !_hadError) Common::hexdump((byte *)&_currentScript->front(), _currentScript->size() * sizeof(inst)); + debugC(2, kDebugLingoCompile, "<resulting code>"); uint pc = 0; while (pc < _currentScript->size()) { Common::String instr = decodeInstruction(_currentScript, pc, &pc); debugC(2, kDebugLingoCompile, "[%5d] %s", pc, instr.c_str()); } + debugC(2, kDebugLingoCompile, "<end code>"); } } |