Skip to content

Commit

Permalink
SCI: Don't suppress loop delta in SCI1 midi
Browse files Browse the repository at this point in the history
This fixes bug #3293354.
  • Loading branch information
wjp committed Apr 16, 2013
1 parent 457f5da commit f280789
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion engines/sci/sound/midiparser_sci.cpp
Expand Up @@ -531,8 +531,11 @@ void MidiParser_SCI::parseNextEvent(EventInfo &info) {
// Check if the hold ID marker is the same as the hold ID
// marker set for that song by cmdSetSoundHold.
// If it is, loop back, but don't stop notes when jumping.
if (info.basic.param2 == _pSnd->hold)
if (info.basic.param2 == _pSnd->hold) {
uint32 extraDelta = info.delta;
jumpToTick(_loopTick, false, false);
_nextEvent.delta += extraDelta;
}
break;
case kUpdateCue:
_dataincAdd = true;
Expand Down Expand Up @@ -635,7 +638,9 @@ void MidiParser_SCI::parseNextEvent(EventInfo &info) {
// treats this case as an infinite loop (bug #3311911).
if (_pSnd->loop || _pSnd->hold > 0) {
// We need to play it again...
uint32 extraDelta = info.delta;
jumpToTick(_loopTick);
_nextEvent.delta += extraDelta;
} else {
_pSnd->status = kSoundStopped;
_pSnd->setSignal(SIGNAL_OFFSET);
Expand Down

0 comments on commit f280789

Please sign in to comment.