diff options
author | Paul Gilbert | 2015-08-10 22:01:02 -0400 |
---|---|---|
committer | Paul Gilbert | 2015-08-10 22:01:02 -0400 |
commit | 9b0bf9e21555fb1760d45792ab4bd6bcb67d08c6 (patch) | |
tree | 9fbe2561aad6363d60f6c85006f49d254285ef25 /engines/sherlock/talk.cpp | |
parent | 60759cfb5d5fcd605543fa4a03400ed34d778667 (diff) | |
download | scummvm-rg350-9b0bf9e21555fb1760d45792ab4bd6bcb67d08c6.tar.gz scummvm-rg350-9b0bf9e21555fb1760d45792ab4bd6bcb67d08c6.tar.bz2 scummvm-rg350-9b0bf9e21555fb1760d45792ab4bd6bcb67d08c6.zip |
SHERLOCK: RT: Beginnings of speech code
Diffstat (limited to 'engines/sherlock/talk.cpp')
-rw-r--r-- | engines/sherlock/talk.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/engines/sherlock/talk.cpp b/engines/sherlock/talk.cpp index 1b12c6afb4..a998c58605 100644 --- a/engines/sherlock/talk.cpp +++ b/engines/sherlock/talk.cpp @@ -571,6 +571,10 @@ void Talk::loadTalkFile(const Common::String &filename) { Common::String talkFile = chP ? Common::String(filename.c_str(), chP) + ".tlk" : Common::String(filename.c_str(), filename.c_str() + 7) + ".tlk"; + // Create the base of the sound filename used for talking in Rose Tattoo + if (IS_ROSE_TATTOO && _scriptMoreFlag != 1) + sound._talkSoundFile = filename + "."; + // Open the talk file for reading Common::SeekableReadStream *talkStream = res.load(talkFile); _converseNum = res.resourceIndex(); @@ -924,8 +928,13 @@ int Talk::waitForMore(int delay) { events.setCursor(ui._lookScriptFlag ? MAGNIFY : ARROW); } + if (sound._speechOn && !sound._talkSoundFile.empty()) { + sound.playSpeech(sound._talkSoundFile); + sound._talkSoundFile.setChar(sound._talkSoundFile.lastChar() + 1, sound._talkSoundFile.size() - 1); + } + do { - if (sound._speechOn && !*sound._soundIsOn) + if (IS_SERRATED_SCALPEL && sound._speechOn && !*sound._soundIsOn) people._portrait._frameNumber = -1; scene.doBgAnim(); @@ -992,6 +1001,7 @@ int Talk::waitForMore(int delay) { break; } + sound._speechOn = false; events.setCursor(_talkToAbort ? ARROW : oldCursor); events._pressed = events._released = false; |