aboutsummaryrefslogtreecommitdiff
path: root/script_v1.cpp
diff options
context:
space:
mode:
authorNicolas Bacca2002-04-07 00:47:55 +0000
committerNicolas Bacca2002-04-07 00:47:55 +0000
commit37116811cce42c3cab1378b0f77e76f1e52ab37a (patch)
treebf2dfaca504ee3998d4bb191cfc2808ac183cff5 /script_v1.cpp
parentd5d4c8d1785cc914e643871eaa9568249b1709bd (diff)
downloadscummvm-rg350-37116811cce42c3cab1378b0f77e76f1e52ab37a.tar.gz
scummvm-rg350-37116811cce42c3cab1378b0f77e76f1e52ab37a.tar.bz2
scummvm-rg350-37116811cce42c3cab1378b0f77e76f1e52ab37a.zip
Small fix for MP3 CD music (successful cast sound, and a little bit more synchronized in cutscenes)
svn-id: r3884
Diffstat (limited to 'script_v1.cpp')
-rw-r--r--script_v1.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/script_v1.cpp b/script_v1.cpp
index 0b8505900f..aa9108be77 100644
--- a/script_v1.cpp
+++ b/script_v1.cpp
@@ -2479,8 +2479,15 @@ void Scumm::decodeParseString() {
string[textSlot].overhead = true;
break;
case 8: { /* play loom talkie sound - use in other games ? */
- int offset = (int)(getVarOrDirectWord(0x80) * 7.5 - 22650);
- int delay = (int)(getVarOrDirectWord(0x40) * 7.5) + 10;
+ int x = getVarOrDirectWord(0x80);
+ int offset;
+ int delay;
+
+ if (x != 0)
+ offset = (int)((x & 0xffff) * 7.5 - 22650);
+ else
+ offset = 0;
+ delay = (int)((getVarOrDirectWord(0x40) & 0xffff) * 7.5);
if (_gameId == GID_LOOM256)
cd_play(this, 1, 0, offset, delay);