summaryrefslogtreecommitdiff
path: root/src/s_sound.c
diff options
context:
space:
mode:
authorSimon Howard2009-09-13 00:15:24 +0000
committerSimon Howard2009-09-13 00:15:24 +0000
commit7e2eaa105e270586e81c04fdf61bcafd7c96a34c (patch)
treeab40c7e549d055ea01db1519c81f8901e25875b9 /src/s_sound.c
parent2b40842eeca7386f6bfe9b1b39760c8a4d69ca71 (diff)
downloadchocolate-doom-7e2eaa105e270586e81c04fdf61bcafd7c96a34c.tar.gz
chocolate-doom-7e2eaa105e270586e81c04fdf61bcafd7c96a34c.tar.bz2
chocolate-doom-7e2eaa105e270586e81c04fdf61bcafd7c96a34c.zip
Change intro/introa fix to be more accurate: Doom uses d_intro, but
transforms this to d_introa when using OPL playback (thanks entryway) Subversion-branch: /branches/opl-branch Subversion-revision: 1672
Diffstat (limited to 'src/s_sound.c')
-rw-r--r--src/s_sound.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/s_sound.c b/src/s_sound.c
index f038e9cd..9e70ec73 100644
--- a/src/s_sound.c
+++ b/src/s_sound.c
@@ -804,6 +804,15 @@ void S_ChangeMusic(int musicnum, int looping)
char namebuf[9];
void *handle;
+ // The Doom IWAD file has two versions of the intro music: d_intro
+ // and d_introa. The latter is used for OPL playback.
+
+ if (musicnum == mus_intro && (snd_musicdevice == SNDDEVICE_ADLIB
+ || snd_musicdevice == SNDDEVICE_SB))
+ {
+ musicnum = mus_introa;
+ }
+
if (musicnum <= mus_None || musicnum >= NUMMUSIC)
{
I_Error("Bad music number %d", musicnum);