SCI: Always reset hold when starting a new song. Fixes bug #3413589 - "SCI: KQ6CD: Game stops responding in the catacombs"

kDoSoundSetHold is always called after kDoSoundPlay. A regression from
commit 4f3b85f4ef
This commit is contained in:
Filippos Karapetis 2011-09-24 18:44:57 +03:00
parent 5e47c2cfb1
commit e552bc57ba

View file

@ -163,6 +163,9 @@ void SoundCommandParser::processPlaySound(reg_t obj) {
musicSlot->loop = readSelectorValue(_segMan, obj, SELECTOR(loop));
musicSlot->priority = readSelectorValue(_segMan, obj, SELECTOR(priority));
// Reset hold when starting a new song. kDoSoundSetHold is always called after
// kDoSoundPlay to set it properly, if needed. Fixes bug #3413589.
musicSlot->hold = -1;
if (_soundVersion >= SCI_VERSION_1_EARLY)
musicSlot->volume = readSelectorValue(_segMan, obj, SELECTOR(vol));