shithub: choc

Download patch

ref: 5efd8b3ab36302b05618821454d483ac69bb8569
parent: 45b03b36c7b64f5dc884b53e44d899cf18ad5bec
author: James Haley <[email protected]>
date: Sat Sep 24 22:32:12 EDT 2011

Temporary hack to avoid needing an Excedrin.

Subversion-branch: /branches/v2-branch
Subversion-revision: 2403

--- a/src/strife/d_main.c
+++ b/src/strife/d_main.c
@@ -1283,6 +1283,8 @@
 //
 void D_IntroTick(void)
 {
+    int savedvol;
+    
     if(devparm)
         return;
 
@@ -1290,7 +1292,10 @@
     if(introprogress >= MAXINTROPROGRESS)
     {
         D_IntroBackground(); // haleyjd: clear the bg anyway
+        savedvol = sfxVolume;
+        S_SetSfxVolume(4*8); // haleyjd 20110924: temporary hack...
         S_StartSound(NULL, sfx_psdtha);
+        S_SetSfxVolume(savedvol*8);
     }
     else
         D_DrawIntroSequence();
@@ -1659,8 +1664,13 @@
 
     // haleyjd 20110206 [STRIFE] Startup the introduction sequence
     D_InitIntroSequence();
-    D_IntroTick();
 
+    // haleyjd 20110924: moved S_Init up to here
+    if(devparm) // [STRIFE]
+        DEH_printf("S_Init: Setting up sound.\n");
+    S_Init (sfxVolume * 8, musicVolume * 8, voiceVolume * 8); // [STRIFE]: voice
+    D_IntroTick(); // [STRIFE]
+
     // Check for -file in shareware
     if (modifiedgame)
     {
@@ -1865,10 +1875,8 @@
     M_Init ();
     D_IntroTick(); // [STRIFE]
 
-    if(devparm) // [STRIFE]
-        DEH_printf("S_Init: Setting up sound.\n");
-    S_Init (sfxVolume * 8, musicVolume * 8, voiceVolume * 8); // [STRIFE]: voice
-    D_IntroTick(); // [STRIFE]
+    // haleyjd 20110924: Moved S_Init up.
+    D_IntroTick();
 
     // haleyjd 20110220: This stuff was done in I_StartupSound in vanilla, but 
     // we'll do it here instead so we don't have to modify the low-level shared