diff options
author | Simon Howard | 2008-09-25 19:31:14 +0000 |
---|---|---|
committer | Simon Howard | 2008-09-25 19:31:14 +0000 |
commit | adc6a405ba0d2b77cf227184044186a84a971161 (patch) | |
tree | 3c1332cc038feb3d9d6f6e0d002b827d5349398f /src/doom | |
parent | 80ef754afea340ed4f06c780b3a025f23538db04 (diff) | |
download | chocolate-doom-adc6a405ba0d2b77cf227184044186a84a971161.tar.gz chocolate-doom-adc6a405ba0d2b77cf227184044186a84a971161.tar.bz2 chocolate-doom-adc6a405ba0d2b77cf227184044186a84a971161.zip |
Make ENDOOM screen work on Heretic.
Subversion-branch: /branches/raven-branch
Subversion-revision: 1284
Diffstat (limited to 'src/doom')
-rw-r--r-- | src/doom/d_main.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/doom/d_main.c b/src/doom/d_main.c index a6f85f07..2da2efa8 100644 --- a/src/doom/d_main.c +++ b/src/doom/d_main.c @@ -132,6 +132,8 @@ boolean storedemo; char wadfile[1024]; // primary wad file char mapdir[1024]; // directory of development maps +int show_endoom = 1; + void D_CheckNetGame (void); void D_ProcessEvents (void); @@ -359,6 +361,7 @@ void D_BindVariables(void) M_BindVariable("snd_channels", &snd_channels); M_BindVariable("vanilla_savegame_limit", &vanilla_savegame_limit); M_BindVariable("vanilla_demo_limit", &vanilla_demo_limit); + M_BindVariable("show_endoom", &show_endoom); // Multiplayer chat macros @@ -805,6 +808,25 @@ static void LoadChexDeh(void) } } +// Function called at exit to display the ENDOOM screen + +static void D_Endoom(void) +{ + byte *endoom; + + // Don't show ENDOOM if we have it disabled, or we're running + // in screensaver or control test mode. + + if (!show_endoom || screensaver_mode || M_CheckParm("-testcontrols") > 0) + { + return; + } + + endoom = W_CacheLumpName(DEH_String("ENDOOM"), PU_STATIC); + + I_Endoom(endoom); +} + // // D_DoomMain // @@ -814,6 +836,8 @@ void D_DoomMain (void) char file[256]; char demolumpname[9]; + I_AtExit(D_Endoom, false); + M_FindResponseFile (); // Undocumented "search for IWADs" parameter used by the setup |