[Scummvm-cvs-logs] SF.net SVN: scummvm: [28348] scummvm/trunk/engines/saga/sfuncs.cpp

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Tue Jul 31 03:21:25 CEST 2007


Revision: 28348
          http://scummvm.svn.sourceforge.net/scummvm/?rev=28348&view=rev
Author:   thebluegr
Date:     2007-07-30 18:21:25 -0700 (Mon, 30 Jul 2007)

Log Message:
-----------
Play MIDI music at the volume specified in the options screen

Modified Paths:
--------------
    scummvm/trunk/engines/saga/sfuncs.cpp

Modified: scummvm/trunk/engines/saga/sfuncs.cpp
===================================================================
--- scummvm/trunk/engines/saga/sfuncs.cpp	2007-07-31 00:52:00 UTC (rev 28347)
+++ scummvm/trunk/engines/saga/sfuncs.cpp	2007-07-31 01:21:25 UTC (rev 28348)
@@ -1752,7 +1752,7 @@
 		int16 param = thread->pop() + 9;
 
 		if (param >= 9 && param <= 34) {
-			_vm->_music->setVolume(-1, 1);
+			_vm->_music->setVolume(_vm->_musicVolume == 10 ? -1 : _vm->_musicVolume * 25, 1);
 			_vm->_music->play(param);
 		} else {
 			_vm->_music->stop();
@@ -1769,7 +1769,7 @@
 		if (param1 >= _vm->_music->_songTableLen) {
 			warning("sfPlayMusic: Wrong song number (%d > %d)", param1, _vm->_music->_songTableLen - 1);
 		} else {
-			_vm->_music->setVolume(-1, 1);
+			_vm->_music->setVolume(_vm->_musicVolume == 10 ? -1 : _vm->_musicVolume * 25, 1);
 			_vm->_music->play(_vm->_music->_songTable[param1], param2 ? MUSIC_LOOP : MUSIC_NORMAL);
 			if (!_vm->_scene->haveChapterPointsChanged()) {
 				_vm->_scene->setCurrentMusicTrack(param1);
@@ -2206,7 +2206,7 @@
 	if (param1 >= _vm->_music->_songTableLen) {
 		warning("sfQueueMusic: Wrong song number (%d > %d)", param1, _vm->_music->_songTableLen - 1);
 	} else {
-		_vm->_music->setVolume(-1, 1);
+		_vm->_music->setVolume(_vm->_musicVolume == 10 ? -1 : _vm->_musicVolume * 25, 1);
 		event.type = kEvTOneshot;
 		event.code = kMusicEvent;
 		event.param = _vm->_music->_songTable[param1];


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