From 1085bd26b583b6300c2c3c6def7448d8ace05842 Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Thu, 10 Nov 2005 01:41:56 +0000 Subject: More accurate video opcodes output. svn-id: r19544 --- simon/debug.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'simon/debug.cpp') diff --git a/simon/debug.cpp b/simon/debug.cpp index 8692c22189..8ce2f3101a 100644 --- a/simon/debug.cpp +++ b/simon/debug.cpp @@ -176,7 +176,7 @@ void SimonEngine::dump_video_script(const byte *src, bool one_opcode_only) { const char *str, *strn; do { - if (!(_game & GF_SIMON2)) { + if (_game & GF_SIMON1) { opcode = READ_BE_UINT16(src); src += 2; } else { @@ -209,10 +209,13 @@ void SimonEngine::dump_video_script(const byte *src, bool one_opcode_only) { case 'b': fprintf(_dumpFile, "%d ", *src++); break; - case 'd': - fprintf(_dumpFile, "%d ", readUint16Wrapper(src)); - src += 2; - break; + case 'd': { + int16 tmp = (int16)readUint16Wrapper(src); + if (tmp < 0) tmp = vc_read_var(-tmp); + fprintf(_dumpFile, "%d ", tmp); + src += 2; + break; + } case 'v': fprintf(_dumpFile, "[%d] ", readUint16Wrapper(src)); src += 2; -- cgit v1.2.3