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

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Tue Jan 26 23:04:33 CET 2010


Revision: 47576
          http://scummvm.svn.sourceforge.net/scummvm/?rev=47576&view=rev
Author:   thebluegr
Date:     2010-01-26 22:04:33 +0000 (Tue, 26 Jan 2010)

Log Message:
-----------
Fixed loading of old saved games

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

Modified: scummvm/trunk/engines/sci/sound/soundcmd.cpp
===================================================================
--- scummvm/trunk/engines/sci/sound/soundcmd.cpp	2010-01-26 21:27:13 UTC (rev 47575)
+++ scummvm/trunk/engines/sci/sound/soundcmd.cpp	2010-01-26 22:04:33 UTC (rev 47576)
@@ -1047,22 +1047,23 @@
 
 	const MusicList::iterator end = _music->getPlayListEnd();
 	for (MusicList::iterator i = _music->getPlayListStart(); i != end; ++i) {
-		if (savegame_version < 14) {
-			(*i)->dataInc = GET_SEL32V(_segMan, (*i)->soundObj, dataInc);
-			(*i)->signal = GET_SEL32V(_segMan, (*i)->soundObj, signal);
-
-			if (_soundVersion >= SCI_VERSION_1_LATE)
-				(*i)->volume = GET_SEL32V(_segMan, (*i)->soundObj, vol);
-		}
-
 		if ((*i)->resnum && _resMan->testResource(ResourceId(kResourceTypeSound, (*i)->resnum))) {
 			(*i)->soundRes = new SoundResource((*i)->resnum, _resMan, _soundVersion);
 			_music->soundInitSnd(*i);
 		} else {
 			(*i)->soundRes = 0;
 		}
-		if ((*i)->status == kSoundPlaying)
+		if ((*i)->status == kSoundPlaying) {
+			if (savegame_version < 14) {
+				(*i)->dataInc = GET_SEL32V(_segMan, (*i)->soundObj, dataInc);
+				(*i)->signal = GET_SEL32V(_segMan, (*i)->soundObj, signal);
+
+				if (_soundVersion >= SCI_VERSION_1_LATE)
+					(*i)->volume = GET_SEL32V(_segMan, (*i)->soundObj, vol);
+			}
+
 			cmdPlaySound((*i)->soundObj, 0);
+		}
 	}
 
 #endif


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