summaryrefslogtreecommitdiff
path: root/src/doom
diff options
context:
space:
mode:
authorSimon Howard2014-03-25 22:39:51 -0400
committerSimon Howard2014-03-25 22:39:51 -0400
commit9981c42b4a8ab3000b22b9acf6ad4b0edd4b0ae7 (patch)
tree3abaed53b3e757cd5e12d4eeadc9f28e5f94a161 /src/doom
parentbc8517a05648054df17e556d4116e63a20fef75a (diff)
downloadchocolate-doom-9981c42b4a8ab3000b22b9acf6ad4b0edd4b0ae7.tar.gz
chocolate-doom-9981c42b4a8ab3000b22b9acf6ad4b0edd4b0ae7.tar.bz2
chocolate-doom-9981c42b4a8ab3000b22b9acf6ad4b0edd4b0ae7.zip
Set GUS patch path variable using D_SetVariable.
commit 42faefce1fd03 added code to set the GUS patch path automatically when the BFG Edition is installed, but this caused problems because gusconf.c is not included as part of the build for the setup tool. Use D_SetVariable() instead which accomplishes the same thing without a hard dependency.
Diffstat (limited to 'src/doom')
-rw-r--r--src/doom/d_main.c25
1 files changed, 13 insertions, 12 deletions
diff --git a/src/doom/d_main.c b/src/doom/d_main.c
index b2566176..e6b993c4 100644
--- a/src/doom/d_main.c
+++ b/src/doom/d_main.c
@@ -1156,18 +1156,6 @@ void D_DoomMain (void)
DEH_Init();
#endif
- iwadfile = D_FindIWAD(IWAD_MASK_DOOM, &gamemission);
-
- // None found?
-
- if (iwadfile == NULL)
- {
- I_Error("Game mode indeterminate. No IWAD file was found. Try\n"
- "specifying one with the '-iwad' command line parameter.\n");
- }
-
- modifiedgame = false;
-
//!
// @vanilla
//
@@ -1293,6 +1281,19 @@ void D_DoomMain (void)
// Save configuration at exit.
I_AtExit(M_SaveDefaults, false);
+ // Find main IWAD file and load it.
+ iwadfile = D_FindIWAD(IWAD_MASK_DOOM, &gamemission);
+
+ // None found?
+
+ if (iwadfile == NULL)
+ {
+ I_Error("Game mode indeterminate. No IWAD file was found. Try\n"
+ "specifying one with the '-iwad' command line parameter.\n");
+ }
+
+ modifiedgame = false;
+
DEH_printf("W_Init: Init WADfiles.\n");
D_AddFile(iwadfile);