aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWillem Jan Palenstijn2015-02-18 09:33:03 +0100
committerWillem Jan Palenstijn2015-02-18 09:33:03 +0100
commit4f6f0fb148133df632104071185efa049c7d5fea (patch)
treecb4c1fa465a8ee6c4c9c6b37e4c10e0eed8e1624
parentfdc09c2cb7ff3041dbd11c146d3d669cc7aa4777 (diff)
downloadscummvm-rg350-4f6f0fb148133df632104071185efa049c7d5fea.tar.gz
scummvm-rg350-4f6f0fb148133df632104071185efa049c7d5fea.tar.bz2
scummvm-rg350-4f6f0fb148133df632104071185efa049c7d5fea.zip
SCI: Fix digital audio
Regression from 5028487038fd, where I assumed all songs were MIDI.
-rw-r--r--engines/sci/sound/soundcmd.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/sci/sound/soundcmd.cpp b/engines/sci/sound/soundcmd.cpp
index 64991cbf5c..ee5903fda2 100644
--- a/engines/sci/sound/soundcmd.cpp
+++ b/engines/sci/sound/soundcmd.cpp
@@ -186,7 +186,9 @@ void SoundCommandParser::processPlaySound(reg_t obj, bool playBed) {
musicSlot->loop = readSelectorValue(_segMan, obj, SELECTOR(loop));
// Get song priority from either obj or soundRes
- byte resourcePriority = musicSlot->soundRes->getSoundPriority();
+ byte resourcePriority = 0xFF;
+ if (musicSlot->soundRes)
+ resourcePriority = musicSlot->soundRes->getSoundPriority();
if (!musicSlot->overridePriority && resourcePriority != 0xFF) {
musicSlot->priority = resourcePriority;
} else {