aboutsummaryrefslogtreecommitdiff
path: root/engines/mohawk/riven.cpp
diff options
context:
space:
mode:
authorBastien Bouclet2017-06-25 11:35:32 +0200
committerEugene Sandulenko2017-07-03 08:50:10 +0200
commit44943e1285f128dc1975789b937dd6540bbaa301 (patch)
tree14d082a40215cb2629111078565be6d6e23c60cc /engines/mohawk/riven.cpp
parentf977b5712328133b638c33992d4e111624d1881d (diff)
downloadscummvm-rg350-44943e1285f128dc1975789b937dd6540bbaa301.tar.gz
scummvm-rg350-44943e1285f128dc1975789b937dd6540bbaa301.tar.bz2
scummvm-rg350-44943e1285f128dc1975789b937dd6540bbaa301.zip
MOHAWK: Change the delay function not to have an event loop
Fixes events getting lost during delays
Diffstat (limited to 'engines/mohawk/riven.cpp')
-rw-r--r--engines/mohawk/riven.cpp14
1 files changed, 2 insertions, 12 deletions
diff --git a/engines/mohawk/riven.cpp b/engines/mohawk/riven.cpp
index 52784e58e4..0288266daf 100644
--- a/engines/mohawk/riven.cpp
+++ b/engines/mohawk/riven.cpp
@@ -447,21 +447,11 @@ Common::SeekableReadStream *MohawkEngine_Riven::getExtrasResource(uint32 tag, ui
return _extrasFile->getResource(tag, id);
}
-void MohawkEngine_Riven::delayAndUpdate(uint32 ms) {
+void MohawkEngine_Riven::delay(uint32 ms) {
uint32 startTime = _system->getMillis();
while (_system->getMillis() < startTime + ms && !shouldQuit()) {
- _sound->updateSLST();
- _stack->onFrame();
- _video->updateMovies();
-
- Common::Event event;
- while (_system->getEventManager()->pollEvent(event))
- ;
-
- _system->updateScreen();
-
- _system->delayMillis(10); // Ease off the CPU
+ doFrame();
}
}