[Scummvm-cvs-logs] SF.net SVN: scummvm:[44073] scummvm/trunk

eriktorbjorn at users.sourceforge.net eriktorbjorn at users.sourceforge.net
Sun Sep 13 23:38:48 CEST 2009


Revision: 44073
          http://scummvm.svn.sourceforge.net/scummvm/?rev=44073&view=rev
Author:   eriktorbjorn
Date:     2009-09-13 21:38:47 +0000 (Sun, 13 Sep 2009)

Log Message:
-----------
Fixed bug #2847910, "Loss of background audio loop". It would probably be safe
to backport this to the 1.0 branch, but I'm not 100% sure, and it's getting
pretty late here. (On the other hand, the missing sound effects are pretty
faint, at least in the cases I've seen, so we haven't been missing much. That's
probably why it's gone unnoticed until now.)

Modified Paths:
--------------
    scummvm/trunk/NEWS
    scummvm/trunk/engines/sword1/control.cpp
    scummvm/trunk/engines/sword1/sound.cpp

Modified: scummvm/trunk/NEWS
===================================================================
--- scummvm/trunk/NEWS	2009-09-13 21:12:05 UTC (rev 44072)
+++ scummvm/trunk/NEWS	2009-09-13 21:38:47 UTC (rev 44073)
@@ -19,6 +19,9 @@
    - Added support for music and sound effects in the the Amiga version of
      The Secret of Monkey Island.
 
+ Broken Sword 1:
+   - Fixed missing background sound effects in some rooms.
+
 1.0.0 (2009-10-XX)
  New Ports:
    - Added MotoEZX and MotoMAGX ports.

Modified: scummvm/trunk/engines/sword1/control.cpp
===================================================================
--- scummvm/trunk/engines/sword1/control.cpp	2009-09-13 21:12:05 UTC (rev 44072)
+++ scummvm/trunk/engines/sword1/control.cpp	2009-09-13 21:38:47 UTC (rev 44073)
@@ -416,7 +416,10 @@
 	_system->copyRectToScreen(_screenBuf, 640, 0, 0, 640, 480);
 	free(_screenBuf);
 	_mouse->controlPanel(false);
-	_music->startMusic(Logic::_scriptVars[CURRENT_MUSIC], 1);
+	if (retVal == CONTROL_NOTHING_DONE) {
+		_music->startMusic(Logic::_scriptVars[CURRENT_MUSIC], 1);
+		_sound->newScreen(Logic::_scriptVars[SCREEN]);
+	}
 	_panelShown = false;
 	return retVal;
 }

Modified: scummvm/trunk/engines/sword1/sound.cpp
===================================================================
--- scummvm/trunk/engines/sword1/sound.cpp	2009-09-13 21:12:05 UTC (rev 44072)
+++ scummvm/trunk/engines/sword1/sound.cpp	2009-09-13 21:38:47 UTC (rev 44073)
@@ -226,6 +226,16 @@
 			closeCowSystem();
 		initCowSystem();
 	}
+
+	// Start the room's looping sounds.
+	for (uint16 cnt = 0; cnt < TOTAL_FX_PER_ROOM; cnt++) {
+		uint16 fxNo = _roomsFixedFx[screen][cnt];
+		if (fxNo) {
+			if (_fxList[fxNo].type == FX_LOOP)
+				addToQueue(fxNo);
+		} else
+			break;
+	}
 }
 
 void Sound::quitScreen(void) {


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