diff options
Diffstat (limited to 'engines/mohawk')
-rw-r--r-- | engines/mohawk/riven.cpp | 14 | ||||
-rw-r--r-- | engines/mohawk/riven.h | 2 | ||||
-rw-r--r-- | engines/mohawk/riven_scripts.cpp | 3 |
3 files changed, 4 insertions, 15 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(); } } diff --git a/engines/mohawk/riven.h b/engines/mohawk/riven.h index 1cb8d9dbdf..32863d6ecf 100644 --- a/engines/mohawk/riven.h +++ b/engines/mohawk/riven.h @@ -152,7 +152,7 @@ public: bool _activatedPLST; bool _activatedSLST; void runLoadDialog(); - void delayAndUpdate(uint32 ms); + void delay(uint32 ms); // Timer void installTimer(TimerProc *proc, uint32 time); diff --git a/engines/mohawk/riven_scripts.cpp b/engines/mohawk/riven_scripts.cpp index e6ebd6e281..9cb6a04b1b 100644 --- a/engines/mohawk/riven_scripts.cpp +++ b/engines/mohawk/riven_scripts.cpp @@ -462,13 +462,12 @@ void RivenSimpleCommand::stopSound(uint16 op, uint16 argc, uint16 *argv) { // Command 13: set mouse cursor (cursor_id) void RivenSimpleCommand::changeCursor(uint16 op, uint16 argc, uint16 *argv) { _vm->_cursor->setCursor(argv[0]); - _vm->_system->updateScreen(); } // Command 14: pause script execution (delay in ms, u1) void RivenSimpleCommand::delay(uint16 op, uint16 argc, uint16 *argv) { if (argv[0] > 0) - _vm->delayAndUpdate(argv[0]); + _vm->delay(argv[0]); } // Command 17: call external command |