aboutsummaryrefslogtreecommitdiff
path: root/scumm/script_v8.cpp
diff options
context:
space:
mode:
authorMax Horn2003-04-07 16:04:30 +0000
committerMax Horn2003-04-07 16:04:30 +0000
commitca7c8081a1c35d90a9f1743fbccf57b4304d96e5 (patch)
tree22785ca28c7eca3ee8c99f78dab68dca0e927d5a /scumm/script_v8.cpp
parentdf9ccab93590894f546e5fee86cad513016bc49e (diff)
downloadscummvm-rg350-ca7c8081a1c35d90a9f1743fbccf57b4304d96e5.tar.gz
scummvm-rg350-ca7c8081a1c35d90a9f1743fbccf57b4304d96e5.tar.bz2
scummvm-rg350-ca7c8081a1c35d90a9f1743fbccf57b4304d96e5.zip
Patch #712493: CMI: Object line
svn-id: r6930
Diffstat (limited to 'scumm/script_v8.cpp')
-rw-r--r--scumm/script_v8.cpp27
1 files changed, 22 insertions, 5 deletions
diff --git a/scumm/script_v8.cpp b/scumm/script_v8.cpp
index ac09e727df..95fcb574dc 100644
--- a/scumm/script_v8.cpp
+++ b/scumm/script_v8.cpp
@@ -515,11 +515,14 @@ void Scumm_v8::decodeParseString(int m, int n) {
}
pointer[j] = 0;
- // Stop any talking that's still going on
- if (_sound->_talkChannel > -1)
- _mixer->stop(_sound->_talkChannel);
+ int new_sound = _sound->playBundleSound(pointer);
+ if (new_sound != -1) {
+ // Stop any talking that's still going on
+ if (_sound->_talkChannel > -1)
+ _mixer->stop(_sound->_talkChannel);
+ _sound->_talkChannel = new_sound;
+ }
- _sound->_talkChannel = _sound->playBundleSound(pointer);
_messagePtr = _transText;
}
@@ -607,10 +610,24 @@ void Scumm::drawBlastTexts() {
_charset->_nextTop = _charset->_top;
}
} while (c);
+
+ _blastTextQueue[i].left = _charset->_strLeft;
+ _blastTextQueue[i].right = _charset->_strRight;
+ _blastTextQueue[i].top = _charset->_strTop;
+ _blastTextQueue[i].bottom = _charset->_strBottom;
}
_charset->_ignoreCharsetMask = false;
}
+void Scumm::removeBlastTexts() {
+ int i;
+
+ for (i = 0; i < _blastTextQueuePos; i++) {
+ restoreBG(_blastTextQueue[i].left, _blastTextQueue[i].top, _blastTextQueue[i].right, _blastTextQueue[i].bottom);
+ }
+ _blastTextQueuePos = 0;
+}
+
void Scumm_v8::o8_mod() {
int a = pop();
push(pop() % a);
@@ -1614,7 +1631,7 @@ void Scumm_v8::o8_kernelGetFunctions() {
// scripts. Probably a wrong push/pop somewhere. For now override to correct value.
array = 658;
ArrayHeader *ah = (ArrayHeader *)getResourceAddress(rtString, readVar(array));
- if (!strcmp((char *)ah->data, "Saveload Page"))
+ if (!strcmp((char *)ah->data, "Saveload Page") || !strcmp((char *)ah->data, "Object Names"))
push(1);
else
push(0);