[Scummvm-cvs-logs] scummvm master -> a7fe40d3b18aa23d76ea33381efa6b48414abe2b

Kirben kirben at optusnet.com.au
Sun Jul 5 03:21:46 CEST 2015


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
a7fe40d3b1 AGOS: The sound effects in Simon the Sorcerer 1 (Floppy) are only meant for Adlib.


Commit: a7fe40d3b18aa23d76ea33381efa6b48414abe2b
    https://github.com/scummvm/scummvm/commit/a7fe40d3b18aa23d76ea33381efa6b48414abe2b
Author: Kirben (kirben at optusnet.com.au)
Date: 2015-07-05T11:20:39+10:00

Commit Message:
AGOS: The sound effects in Simon the Sorcerer 1 (Floppy) are only meant for Adlib.

Changed paths:
    engines/agos/midi.cpp
    engines/agos/midi.h
    engines/agos/res_snd.cpp



diff --git a/engines/agos/midi.cpp b/engines/agos/midi.cpp
index 552b27a..85f2dd5 100644
--- a/engines/agos/midi.cpp
+++ b/engines/agos/midi.cpp
@@ -54,6 +54,7 @@ MidiPlayer::MidiPlayer() {
 
 	_adlibPatches = NULL;
 
+	_adLibMusic = false;
 	_enable_sfx = true;
 	_current = 0;
 
@@ -235,6 +236,7 @@ int MidiPlayer::open(int gameType, bool isDemo) {
 	}
 
 	dev = MidiDriver::detectDevice(MDT_ADLIB | MDT_MIDI | (gameType == GType_SIMON1 ? MDT_PREFER_MT32 : MDT_PREFER_GM));
+	_adLibMusic = (MidiDriver::getMusicType(dev) == MT_ADLIB);
 	_nativeMT32 = ((MidiDriver::getMusicType(dev) == MT_MT32) || ConfMan.getBool("native_mt32"));
 
 	_driver = MidiDriver::createMidi(dev);
diff --git a/engines/agos/midi.h b/engines/agos/midi.h
index 25ebd47..8881047 100644
--- a/engines/agos/midi.h
+++ b/engines/agos/midi.h
@@ -93,6 +93,7 @@ protected:
 	void unloadAdlibPatches();
 
 public:
+	bool _adLibMusic;
 	bool _enable_sfx;
 
 public:
diff --git a/engines/agos/res_snd.cpp b/engines/agos/res_snd.cpp
index 5d6ab60..c02cf96 100644
--- a/engines/agos/res_snd.cpp
+++ b/engines/agos/res_snd.cpp
@@ -309,7 +309,9 @@ void AGOSEngine::stopMusic() {
 }
 
 void AGOSEngine::playSting(uint16 soundId) {
-	if (!_midi->_enable_sfx)
+	// The sound effects in floppy disk version of
+	// Simon the Sorcerer 1 are only meant for AdLib
+	if (!_midi->_adLibMusic || !_midi->_enable_sfx)
 		return;
 
 	char filename[15];






More information about the Scummvm-git-logs mailing list