aboutsummaryrefslogtreecommitdiff
path: root/engines/dm
diff options
context:
space:
mode:
authorBendegúz Nagy2016-09-03 11:12:16 +0200
committerBendegúz Nagy2016-09-03 11:12:16 +0200
commitd059a1cd4b7491e04d10af728ae55a74f0d5035c (patch)
treed85c9bb3950611a265a8ed0e79c3628a45829e29 /engines/dm
parent2e0fae6547e9a69b5f0e308e78e91e56995721f3 (diff)
downloadscummvm-rg350-d059a1cd4b7491e04d10af728ae55a74f0d5035c.tar.gz
scummvm-rg350-d059a1cd4b7491e04d10af728ae55a74f0d5035c.tar.bz2
scummvm-rg350-d059a1cd4b7491e04d10af728ae55a74f0d5035c.zip
DM: Use delayMillis(10) in mainLoop
Diffstat (limited to 'engines/dm')
-rw-r--r--engines/dm/TODOs/todo.txt2
-rw-r--r--engines/dm/dm.cpp7
2 files changed, 6 insertions, 3 deletions
diff --git a/engines/dm/TODOs/todo.txt b/engines/dm/TODOs/todo.txt
index 958375b5b7..64110249a1 100644
--- a/engines/dm/TODOs/todo.txt
+++ b/engines/dm/TODOs/todo.txt
@@ -5,6 +5,8 @@ Bugs:
Logic:
Items thrown on the right side end up on the left side
+ Can't place torch in player's hand after loading, can do so only after brining up the inventory
+ Restarting the game after the party is dead segfaults
Todo:
Add wiki entry for DM
diff --git a/engines/dm/dm.cpp b/engines/dm/dm.cpp
index 538124f087..a0adf5e91b 100644
--- a/engines/dm/dm.cpp
+++ b/engines/dm/dm.cpp
@@ -401,7 +401,7 @@ Common::Error DMEngine::run() {
void DMEngine::gameloop() {
_canLoadFromGMM = true;
- _waitForInputMaxVerticalBlankCount = 10;
+ _waitForInputMaxVerticalBlankCount = 15;
while (true) {
if (_engineShouldQuit) {
_canLoadFromGMM = false;
@@ -503,9 +503,10 @@ void DMEngine::gameloop() {
_eventMan->highlightBoxDisable();
}
- _system->delayMillis(2);
- if (++vblankCounter >= _waitForInputMaxVerticalBlankCount * 4)
+ if (++vblankCounter > _waitForInputMaxVerticalBlankCount)
_stopWaitingForPlayerInput = true;
+ else if (!_stopWaitingForPlayerInput)
+ _system->delayMillis(10);
} while (!_stopWaitingForPlayerInput || !_gameTimeTicking);
}