diff options
author | Johannes Schickel | 2006-01-03 19:03:09 +0000 |
---|---|---|
committer | Johannes Schickel | 2006-01-03 19:03:09 +0000 |
commit | f046a14bb22f1d6c138ed82efa03d5ff89ae85e0 (patch) | |
tree | d22406fef62e5982865fccede353ce8658e793a5 /kyra/timer.cpp | |
parent | 025aa4dbb4f714ad88c469411265be8ddd28fd2e (diff) | |
download | scummvm-rg350-f046a14bb22f1d6c138ed82efa03d5ff89ae85e0.tar.gz scummvm-rg350-f046a14bb22f1d6c138ed82efa03d5ff89ae85e0.tar.bz2 scummvm-rg350-f046a14bb22f1d6c138ed82efa03d5ff89ae85e0.zip |
Fixed some bugs with the timers.
also implemented: cmd_dispelMagicAnimation and cmd_runWSAFrames
and implemented color fading of the kyragem in room 210.
svn-id: r19898
Diffstat (limited to 'kyra/timer.cpp')
-rw-r--r-- | kyra/timer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kyra/timer.cpp b/kyra/timer.cpp index 9760ec5287..3c73b5c8b1 100644 --- a/kyra/timer.cpp +++ b/kyra/timer.cpp @@ -93,7 +93,6 @@ void KyraEngine::updateGameTimers() { (*this.*_timers[i].func)(i); _timers[i].nextRun = _system->getMillis() + _timers[i].countdown * _tickLength; - } } if (_timers[i].nextRun < _timerNextRun) @@ -119,8 +118,9 @@ int16 KyraEngine::getTimerDelay(uint8 timer) { void KyraEngine::setTimerCountdown(uint8 timer, int32 countdown) { debug(9, "setTimerCountdown(%i, %i)", timer, countdown); _timers[timer].countdown = countdown; + _timers[timer].nextRun = _system->getMillis() + countdown * _tickLength; - uint32 nextRun = _system->getMillis() + countdown; + uint32 nextRun = _system->getMillis() + countdown * _tickLength; if (nextRun < _timerNextRun) _timerNextRun = nextRun; } |