diff options
author | Max Horn | 2003-05-04 20:07:32 +0000 |
---|---|---|
committer | Max Horn | 2003-05-04 20:07:32 +0000 |
commit | 9659a4b4ed705a0a82b2b52245e7c096536b78a1 (patch) | |
tree | 626db1fa90157e8d473b37b2230b2979b87292af /scumm/script_v2.cpp | |
parent | ab1d0a69e16d2f29fe21a6754f21e368faaeb7df (diff) | |
download | scummvm-rg350-9659a4b4ed705a0a82b2b52245e7c096536b78a1.tar.gz scummvm-rg350-9659a4b4ed705a0a82b2b52245e7c096536b78a1.tar.bz2 scummvm-rg350-9659a4b4ed705a0a82b2b52245e7c096536b78a1.zip |
V2 verbop fix (read verb name from script)
svn-id: r7327
Diffstat (limited to 'scumm/script_v2.cpp')
-rw-r--r-- | scumm/script_v2.cpp | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/scumm/script_v2.cpp b/scumm/script_v2.cpp index 280a83ab91..def5f50021 100644 --- a/scumm/script_v2.cpp +++ b/scumm/script_v2.cpp @@ -742,26 +742,32 @@ void Scumm_v2::o2_resourceRoutines() { } void Scumm_v2::o2_verbOps() { - int opcode = fetchScriptByte(), slot, state; - - switch (opcode) { + int opcode = fetchScriptByte(); + int slot, state; + + switch (opcode) { case 0: // Delete Verb slot = getVarOrDirectByte(0x80); - break; - + break; + case 0xFF: // Verb On/Off slot = fetchScriptByte(); state = fetchScriptByte(); - break; - + break; + default: { // New Verb - fetchScriptByte(); // X - fetchScriptByte(); // Y - getVarOrDirectByte(0x80); // Slot - fetchScriptByte(); // ? + int x = fetchScriptByte(); + int y = fetchScriptByte(); + slot = getVarOrDirectByte(0x80); + int unk = fetchScriptByte(); // ? + + // It follows the verb name + printf("o2_verbOps: opcode = %d, x = %d, y = %d, slot = %d, unk = %d, name = %s\n", + opcode, x, y, slot, unk, _scriptPointer); + _scriptPointer += strlen((char *)_scriptPointer) + 1; + } + break; } - break; - } } void Scumm_v2::o2_isEqual() { |