diff options
author | Robert Špalek | 2009-10-13 04:44:22 +0000 |
---|---|---|
committer | Robert Špalek | 2009-10-13 04:44:22 +0000 |
commit | 7c311057c10f876cbe5053fac1943917766ae0f0 (patch) | |
tree | 49038d4ebb1f73537d7f63145ee6d9fbb4fc458c /engines/draci/game.cpp | |
parent | e77928440307f0d8a765e32100e031989ad25ff5 (diff) | |
download | scummvm-rg350-7c311057c10f876cbe5053fac1943917766ae0f0.tar.gz scummvm-rg350-7c311057c10f876cbe5053fac1943917766ae0f0.tar.bz2 scummvm-rg350-7c311057c10f876cbe5053fac1943917766ae0f0.zip |
Dubbing is played.
I haven't implemented switching dubbing and subtitles on/off according to
the config manager nor the speed of the subtitles, yet.
svn-id: r45001
Diffstat (limited to 'engines/draci/game.cpp')
-rw-r--r-- | engines/draci/game.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/engines/draci/game.cpp b/engines/draci/game.cpp index ff15483cc7..a9cf42c73b 100644 --- a/engines/draci/game.cpp +++ b/engines/draci/game.cpp @@ -414,18 +414,11 @@ void Game::loop() { // Handle character talking (if there is any) if (_loopSubstatus == kSubstatusTalk) { - Animation *speechAnim = _vm->_anims->getAnimation(kSpeechText); - Text *speechFrame = reinterpret_cast<Text *>(speechAnim->getFrame()); - - uint speechDuration = kBaseSpeechDuration + - speechFrame->getLength() * kSpeechTimeUnit / - (128 / 16 + 1); - // If the current speech text has expired or the user clicked a mouse button, // advance to the next line of text if (_vm->_mouse->lButtonPressed() || _vm->_mouse->rButtonPressed() || - (_vm->_system->getMillis() - _speechTick) >= speechDuration) { + (_vm->_system->getMillis() - _speechTick) >= _speechDuration) { _shouldExitLoop = true; _vm->_mouse->lButtonSet(false); @@ -1508,8 +1501,9 @@ const Person *Game::getPerson(int personID) const { return &_persons[personID]; } -void Game::setSpeechTick(uint tick) { +void Game::setSpeechTiming(uint tick, uint duration) { _speechTick = tick; + _speechDuration = duration; } int Game::getEscRoom() const { |