aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/script/script_hof.cpp4
-rw-r--r--engines/kyra/sound/sound.h5
2 files changed, 7 insertions, 2 deletions
diff --git a/engines/kyra/script/script_hof.cpp b/engines/kyra/script/script_hof.cpp
index 94d3a82cc4..ebc10c277a 100644
--- a/engines/kyra/script/script_hof.cpp
+++ b/engines/kyra/script/script_hof.cpp
@@ -817,8 +817,8 @@ int KyraEngine_HoF::o2_showLetter(EMCState *script) {
int KyraEngine_HoF::o2_playFireflyScore(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_playFireflyScore(%p) ()", (const void *)script);
- if (_sound->getSfxType() == Sound::kAdLib || _sound->getSfxType() == Sound::kPCSpkr ||
- _sound->getSfxType() == Sound::kMidiMT32 || _sound->getSfxType() == Sound::kMidiGM) {
+ if ((_sound->getSfxType() == Sound::kAdLib || _sound->getSfxType() == Sound::kPCSpkr || _sound->getSfxType() == Sound::kMidiMT32 ||
+ _sound->getSfxType() == Sound::kMidiGM) && !_sound->useDigitalSfx()) {
snd_playWanderScoreViaMap(86, 1);
return 1;
} else {
diff --git a/engines/kyra/sound/sound.h b/engines/kyra/sound/sound.h
index 6c45d8b59b..531496b39e 100644
--- a/engines/kyra/sound/sound.h
+++ b/engines/kyra/sound/sound.h
@@ -107,6 +107,11 @@ public:
virtual kType getMusicType() const = 0;
virtual kType getSfxType() const;
+ // This is obviously not a real implementation. The original allows disabling digital sfx (or simply not having a suitable sound card),
+ // thus falling back to the music driver's sfx. We never supported this, since we don't even have a setting for it in the launcher.
+ // Currently, the only purpose of this function is fixing KyraEngine_HoF::o2_playFireflyScore() (bug #10877: "Sound issues in the Legend of Kyrandia 2").
+ virtual bool useDigitalSfx() const { return true; }
+
/**
* Initializes the output device.
*