[Scummvm-cvs-logs] SF.net SVN: scummvm:[49114] scummvm/trunk/engines/sci/sound/music.cpp

m_kiewitz at users.sourceforge.net m_kiewitz at users.sourceforge.net
Thu May 20 08:11:47 CEST 2010


Revision: 49114
          http://scummvm.svn.sourceforge.net/scummvm/?rev=49114&view=rev
Author:   m_kiewitz
Date:     2010-05-20 06:11:46 +0000 (Thu, 20 May 2010)

Log Message:
-----------
SCI: fix regression of r49109 - only queue up midi sounds

Modified Paths:
--------------
    scummvm/trunk/engines/sci/sound/music.cpp

Modified: scummvm/trunk/engines/sci/sound/music.cpp
===================================================================
--- scummvm/trunk/engines/sci/sound/music.cpp	2010-05-20 05:48:37 UTC (rev 49113)
+++ scummvm/trunk/engines/sci/sound/music.cpp	2010-05-20 06:11:46 UTC (rev 49114)
@@ -249,7 +249,7 @@
 	for (uint i = 0; i < playListCount; i++) {
 		if (_playList[i] == pSnd)
 			playListNo = i;
-		if (_playList[i]->status == kSoundPlaying)
+		if ((_playList[i]->status == kSoundPlaying) && (_playList[i]->pMidiParser))
 			alreadyPlaying = true;
 	}
 	if (playListNo == playListCount) { // not found
@@ -259,14 +259,16 @@
 
 	_mutex.unlock();	// unlock to perform mixer-related calls
 
-	if ((_soundVersion <= SCI_VERSION_0_LATE) && (alreadyPlaying)) {
-		// if any music is already playing, SCI0 queues music and plays it after the current music has finished
-		//  done by SoundCommandParser::updateSci0Cues()
-		// Example of such case: iceman room 14
-		// FIXME: this code is supposed to also take a look at priority and pause currently playing sound accordingly
-		pSnd->isQueued = true;
-		pSnd->status = kSoundPaused;
-		return;
+	if (pSnd->pMidiParser) {
+		if ((_soundVersion <= SCI_VERSION_0_LATE) && (alreadyPlaying)) {
+			// if any music is already playing, SCI0 queues music and plays it after the current music has finished
+			//  done by SoundCommandParser::updateSci0Cues()
+			// Example of such case: iceman room 14
+			// FIXME: this code is supposed to also take a look at priority and pause currently playing sound accordingly
+			pSnd->isQueued = true;
+			pSnd->status = kSoundPaused;
+			return;
+		}
 	}
 
 	if (pSnd->pStreamAud && !_pMixer->isSoundHandleActive(pSnd->hCurrentAud)) {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list