diff options
author | Max Horn | 2003-07-14 21:37:45 +0000 |
---|---|---|
committer | Max Horn | 2003-07-14 21:37:45 +0000 |
commit | bb87787314d90487d5c4762f94abd944cca196bb (patch) | |
tree | 1d470238cdc391ffc9259f057791efa7f72d7925 /scumm/string.cpp | |
parent | 42d0b2e6f79378558832857b3f1ece4ea57164bf (diff) | |
download | scummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.tar.gz scummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.tar.bz2 scummvm-rg350-bb87787314d90487d5c4762f94abd944cca196bb.zip |
fix for bug #769744 (COMI: Trying to append to a nonexistant stream)
svn-id: r9025
Diffstat (limited to 'scumm/string.cpp')
-rw-r--r-- | scumm/string.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/scumm/string.cpp b/scumm/string.cpp index 08ca156ee6..4ebe58f127 100644 --- a/scumm/string.cpp +++ b/scumm/string.cpp @@ -153,7 +153,7 @@ void Scumm::CHARSET_1() { // FIXME: DIG and CMI never set sfxMode or any actor talk data... // This hack will force the backup cutoff system to be used instead, // unless the talkChannel is null (eg, this string has no sound attached) - if ((_gameId == GID_CMI || _gameId == GID_DIG) && (_sound->_talkChannel >= 0)) + if ((_gameId == GID_CMI || _gameId == GID_DIG) && _sound->_talkChannelHandle) return; if ((_sound->_sfxMode & 2) == 0) @@ -298,7 +298,7 @@ void Scumm::CHARSET_1() { if (_version <= 3) { _charset->printChar(c); } else { - if (_noSubtitles && (_haveMsg == 0xFE || _sound->_talkChannel >= 0)) { + if (_noSubtitles && (_haveMsg == 0xFE || _sound->_talkChannelHandle)) { // Subtitles are turned off, and there is a voice version // of this message -> don't print it. } else @@ -594,7 +594,10 @@ void Scumm::addVerbToStack(int var) pointer[j++] = ptr[i]; } pointer[j] = 0; - _sound->_talkChannel = _sound->playBundleSound(pointer); + + // Play speech + _sound->playBundleSound(pointer, &_sound->_talkChannelHandle); + addMessageToStack(_transText); } else { addMessageToStack(ptr); |