aboutsummaryrefslogtreecommitdiff
path: root/engines/draci
diff options
context:
space:
mode:
authorRobert Špalek2009-11-12 03:25:10 +0000
committerRobert Špalek2009-11-12 03:25:10 +0000
commit13a2b24ab56335d95889f6c015414d1798d37be1 (patch)
treee43c6162664a9e226e42adbb9e5aaff70f66fed3 /engines/draci
parent793761c6954d68e7b38afe54665a1f668f8acc68 (diff)
downloadscummvm-rg350-13a2b24ab56335d95889f6c015414d1798d37be1.tar.gz
scummvm-rg350-13a2b24ab56335d95889f6c015414d1798d37be1.tar.bz2
scummvm-rg350-13a2b24ab56335d95889f6c015414d1798d37be1.zip
Removed 2 TODOs
svn-id: r45851
Diffstat (limited to 'engines/draci')
-rw-r--r--engines/draci/game.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/engines/draci/game.cpp b/engines/draci/game.cpp
index 7e521f56c0..e8bebdc2b5 100644
--- a/engines/draci/game.cpp
+++ b/engines/draci/game.cpp
@@ -1116,9 +1116,11 @@ bool Game::enterNewRoom() {
debugC(1, kDraciLogicDebugLevel, "Entering room %d using gate %d", _newRoom, _newGate);
_vm->_mouse->cursorOff();
- // TODO: maybe wait till all sounds end instead of stopping them.
- // In any case, make sure all sounds are stopped before we deallocate
- // their memory by clearing the cache.
+ // Make sure all sounds are stopped before we deallocate their memory
+ // by clearing the cache. We don't have to wait for sounds to end,
+ // because the timeout for voice is set exactly according to the length
+ // of the sound. If the loop ends earlier, e.g. per user's request, we
+ // do wanna end the sounds immediately.
_vm->_sound->stopAll();
// Clear archives
@@ -1245,8 +1247,9 @@ void Game::positionHeroAsAnim(Animation *anim) {
_hero = anim->getCurrentFramePosition();
// Update our hero coordinates (don't forget that our control point is
- // elsewhere).
- // TODO: what about rounding errors?
+ // elsewhere). This is formula is the exact inverse of the formula
+ // used in positionAnimAsHero() and even rounding errors are exactly
+ // the same.
Drawable *frame = anim->getCurrentFrame();
_hero.x += scummvm_lround(anim->getScaleX() * frame->getWidth() / 2);
_hero.y += scummvm_lround(anim->getScaleY() * frame->getHeight());