diff options
author | Vincent Hamm | 2002-02-15 15:00:48 +0000 |
---|---|---|
committer | Vincent Hamm | 2002-02-15 15:00:48 +0000 |
commit | 224b744e583b5d4ba108c82d0e88ed1331e6514f (patch) | |
tree | e5b277d12d6d37e45a6e7e30ca604a22dae36697 | |
parent | ab021d8b3c52d725680d98825c23b2d6d7a1d5e6 (diff) | |
download | scummvm-rg350-224b744e583b5d4ba108c82d0e88ed1331e6514f.tar.gz scummvm-rg350-224b744e583b5d4ba108c82d0e88ed1331e6514f.tar.bz2 scummvm-rg350-224b744e583b5d4ba108c82d0e88ed1331e6514f.zip |
Fixed a few opcodes...
svn-id: r3592
-rw-r--r-- | script_v1.cpp | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/script_v1.cpp b/script_v1.cpp index 8e7e4464e8..cd5f51bc33 100644 --- a/script_v1.cpp +++ b/script_v1.cpp @@ -84,7 +84,7 @@ void Scumm::setupOpcodes() { &Scumm::o5_cursorCommand, &Scumm::o5_putActorInRoom, &Scumm::o5_delay, - &Scumm::o5_badOpcode, + &Scumm::o5_getObjectState, /* 30 */ &Scumm::o5_matrixOps, &Scumm::o5_getInventoryCount, @@ -1293,8 +1293,15 @@ void Scumm::o5_getObjectOwner() { } void Scumm::o5_getObjectState() { - getResultPos(); - setResult(getState(getVarOrDirectWord(0x80))); + if(_features & GF_SMALL_HEADER) { + if((getState(getVarOrDirectWord(0x80)) &0x0F >>4) != getVarOrDirectByte(0x40)) + o5_jumpRelative(); + else + ignoreScriptWord(); + } else { + getResultPos(); + setResult(getState(getVarOrDirectWord(0x80))); + } } void Scumm::o5_getRandomNr() { @@ -1476,6 +1483,12 @@ void Scumm::o5_loadRoomWithEgo() { void Scumm::o5_matrixOps() { int a,b; + if(_features & GF_OLD256) { /* FIXME: missing function call*/ + a=getVarOrDirectByte(0x80); + b=fetchScriptByte(); + return; + } + _opcode = fetchScriptByte(); switch(_opcode & 0x1F) { case 1: |