diff options
author | Johannes Schickel | 2008-03-26 21:24:22 +0000 |
---|---|---|
committer | Johannes Schickel | 2008-03-26 21:24:22 +0000 |
commit | c9b93985615fb6c1fa9c57f4064d62ef88486784 (patch) | |
tree | be385242ac0b2c87999289869536f8bc264d31b9 /engines | |
parent | 7c33605761fe6a1a0282b454ac36c37464e7f753 (diff) | |
download | scummvm-rg350-c9b93985615fb6c1fa9c57f4064d62ef88486784.tar.gz scummvm-rg350-c9b93985615fb6c1fa9c57f4064d62ef88486784.tar.bz2 scummvm-rg350-c9b93985615fb6c1fa9c57f4064d62ef88486784.zip |
Possible fix for part 1 of bug #1926547 "HoF: Right mouse button messes up gameplay".
svn-id: r31250
Diffstat (limited to 'engines')
-rw-r--r-- | engines/kyra/script_v2.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/engines/kyra/script_v2.cpp b/engines/kyra/script_v2.cpp index 0655da0744..0b75a2c972 100644 --- a/engines/kyra/script_v2.cpp +++ b/engines/kyra/script_v2.cpp @@ -278,9 +278,9 @@ int KyraEngine_v2::o2_displayWsaSequentialFramesLooping(ScriptState *script) { _screen->hideMouse(); int curTime = 0; - while (curTime < maxTimes && !skipFlag()) { + while (curTime < maxTimes) { if (startFrame < endFrame) { - for (int i = startFrame; i <= endFrame && !skipFlag(); ++i) { + for (int i = startFrame; i <= endFrame; ++i) { uint32 endTime = _system->getMillis() + waitTime * _tickLength; _wsaSlots[slot]->displayFrame(i, 0xC000 | copyFlags, 0, 0); _screen->updateScreen(); @@ -288,12 +288,12 @@ int KyraEngine_v2::o2_displayWsaSequentialFramesLooping(ScriptState *script) { do { update(); - if (endTime - _system->getMillis() >= 10) + if (endTime - _system->getMillis() >= 10 && !skipFlag()) delay(10); - } while (_system->getMillis() < endTime); + } while (_system->getMillis() < endTime && !skipFlag()); } } else { - for (int i = startFrame; i >= endFrame && !skipFlag(); --i) { + for (int i = startFrame; i >= endFrame; --i) { uint32 endTime = _system->getMillis() + waitTime * _tickLength; _wsaSlots[slot]->displayFrame(i, 0xC000 | copyFlags, 0, 0); _screen->updateScreen(); @@ -301,9 +301,9 @@ int KyraEngine_v2::o2_displayWsaSequentialFramesLooping(ScriptState *script) { do { update(); - if (endTime - _system->getMillis() >= 10) + if (endTime - _system->getMillis() >= 10 && !skipFlag()) delay(10); - } while (_system->getMillis() < endTime); + } while (_system->getMillis() < endTime && !skipFlag()); } } @@ -336,7 +336,7 @@ int KyraEngine_v2::o2_displayWsaSequentialFrames(ScriptState *script) { _screen->hideMouse(); - while (currentFrame <= lastFrame && !skipFlag()) { + while (currentFrame <= lastFrame) { uint32 endTime = _system->getMillis() + frameDelay; _wsaSlots[index]->displayFrame(currentFrame++, copyParam, 0, 0); _screen->updateScreen(); @@ -366,7 +366,7 @@ int KyraEngine_v2::o2_displayWsaSequence(ScriptState *script) { int currentFrame = 0; const int lastFrame = _wsaSlots[index]->frames(); - while (currentFrame <= lastFrame && !skipFlag()) { + while (currentFrame <= lastFrame) { uint32 endTime = _system->getMillis() + frameDelay; _wsaSlots[index]->displayFrame(currentFrame++, copyParam, 0, 0); if (doUpdate) |