diff options
author | Max Horn | 2003-05-31 21:25:14 +0000 |
---|---|---|
committer | Max Horn | 2003-05-31 21:25:14 +0000 |
commit | 7ffb40e61b3ab0bb14d3315636710963fa406c4e (patch) | |
tree | 839ba1b507ed64ea2db9c5160d360e64272e1457 | |
parent | 30b0702ef50cdcde59be7044ec38595579867926 (diff) | |
download | scummvm-rg350-7ffb40e61b3ab0bb14d3315636710963fa406c4e.tar.gz scummvm-rg350-7ffb40e61b3ab0bb14d3315636710963fa406c4e.tar.bz2 scummvm-rg350-7ffb40e61b3ab0bb14d3315636710963fa406c4e.zip |
cleanup
svn-id: r8193
-rw-r--r-- | scumm/script_v6.cpp | 18 | ||||
-rw-r--r-- | scumm/script_v8.cpp | 18 |
2 files changed, 12 insertions, 24 deletions
diff --git a/scumm/script_v6.cpp b/scumm/script_v6.cpp index 460a4ef535..47e3fd4182 100644 --- a/scumm/script_v6.cpp +++ b/scumm/script_v6.cpp @@ -2042,10 +2042,8 @@ void Scumm_v6::o6_wait() { offs = fetchScriptWordSigned(); actnum = pop(); a = derefActor(actnum, "o6_wait:168"); - if (a->isInCurrentRoom() && a->moving) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->moving) + break; return; case 169: // HACK: For Conroy Bumpus' song in Sam & Max. @@ -2085,10 +2083,8 @@ void Scumm_v6::o6_wait() { offs = fetchScriptWordSigned(); actnum = pop(); a = derefActor(actnum, "o6_wait:226"); - if (a->isInCurrentRoom() && a->needRedraw) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->needRedraw) + break; return; case 232: /* wait until actor stops turning */ // FIXME: This opcode is really odd. It's used a lot in The Dig. @@ -2107,10 +2103,8 @@ void Scumm_v6::o6_wait() { actnum = _curActor; } a = derefActor(actnum, "o6_wait:232b"); - if (a->isInCurrentRoom() && a->moving & MF_TURN) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->moving & MF_TURN) + break; return; default: error("o6_wait: default case 0x%x", subOp); diff --git a/scumm/script_v8.cpp b/scumm/script_v8.cpp index 19b2072f72..aff7085c81 100644 --- a/scumm/script_v8.cpp +++ b/scumm/script_v8.cpp @@ -641,10 +641,8 @@ void Scumm_v8::o8_wait() { offs = fetchScriptWordSigned(); actnum = pop(); a = derefActor(actnum, "o8_wait:SO_WAIT_FOR_ACTOR"); - if (a->moving) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->moving) + break; return; case 0x1F: // SO_WAIT_FOR_MESSAGE Wait for message if (VAR(VAR_HAVE_MSG)) @@ -667,19 +665,15 @@ void Scumm_v8::o8_wait() { offs = fetchScriptWordSigned(); actnum = pop(); a = derefActor(actnum, "o8_wait:SO_WAIT_FOR_ANIMATION"); - if (a->isInCurrentRoom() && a->needRedraw) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->needRedraw) + break; return; case 0x23: // SO_WAIT_FOR_TURN offs = fetchScriptWordSigned(); actnum = pop(); a = derefActor(actnum, "o8_wait:SO_WAIT_FOR_TURN"); - if (a->isInCurrentRoom() && a->moving & MF_TURN) { - _scriptPointer += offs; - o6_breakHere(); - } + if (a->isInCurrentRoom() && a->moving & MF_TURN) + break; return; default: error("o8_wait: default case 0x%x", subOp); |