summaryrefslogtreecommitdiff
path: root/src/g_game.c
diff options
context:
space:
mode:
authorSimon Howard2008-07-25 19:56:39 +0000
committerSimon Howard2008-07-25 19:56:39 +0000
commitb1ece32aaba8bf6b7f233de77b6843af179631b0 (patch)
tree629c0ab92c12efbc6cf983a6301ba478ab5f96ea /src/g_game.c
parent82b4201f850208da35c31b1260841ecd293d31cb (diff)
downloadchocolate-doom-b1ece32aaba8bf6b7f233de77b6843af179631b0.tar.gz
chocolate-doom-b1ece32aaba8bf6b7f233de77b6843af179631b0.tar.bz2
chocolate-doom-b1ece32aaba8bf6b7f233de77b6843af179631b0.zip
Initial chex.exe emulation.
Subversion-branch: /trunk/chocolate-doom Subversion-revision: 1155
Diffstat (limited to 'src/g_game.c')
-rw-r--r--src/g_game.c39
1 files changed, 27 insertions, 12 deletions
diff --git a/src/g_game.c b/src/g_game.c
index fc644778..44e77a74 100644
--- a/src/g_game.c
+++ b/src/g_game.c
@@ -1258,18 +1258,33 @@ void G_DoCompleted (void)
if (automapactive)
AM_Stop ();
- if ( gamemode != commercial)
- switch(gamemap)
- {
- case 8:
- gameaction = ga_victory;
- return;
- case 9:
- for (i=0 ; i<MAXPLAYERS ; i++)
- players[i].didsecret = true;
- break;
- }
-
+ if (gamemode != commercial)
+ {
+ // Chex Quest ends after 5 levels, rather than 8.
+
+ if (gameversion == exe_chex)
+ {
+ if (gamemap == 5)
+ {
+ gameaction = ga_victory;
+ return;
+ }
+ }
+ else
+ {
+ switch(gamemap)
+ {
+ case 8:
+ gameaction = ga_victory;
+ return;
+ case 9:
+ for (i=0 ; i<MAXPLAYERS ; i++)
+ players[i].didsecret = true;
+ break;
+ }
+ }
+ }
+
//#if 0 Hmmm - why?
if ( (gamemap == 8)
&& (gamemode != commercial) )