mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-25 05:48:03 -04:00
umapinfo: bring the implementation in line with PrBoom+ (#178)
* umapinfo: fix the nointermission field, bring the implementation in line with PrBoom+ * fix gcc build * another attempt to fix the gcc build
This commit is contained in:
parent
984058fc81
commit
eeeb8334a5
@ -1062,20 +1062,7 @@ static void G_DoCompleted(void)
|
||||
if (automapactive)
|
||||
AM_Stop();
|
||||
|
||||
if (gamemode != commercial) // kilough 2/7/98
|
||||
switch(gamemap)
|
||||
{
|
||||
case 8:
|
||||
gameaction = ga_victory;
|
||||
return;
|
||||
case 9:
|
||||
for (i=0 ; i<MAXPLAYERS ; i++)
|
||||
players[i].didsecret = true;
|
||||
break;
|
||||
}
|
||||
|
||||
wminfo.didsecret = players[consoleplayer].didsecret;
|
||||
wminfo.epsd = gameepisode -1;
|
||||
wminfo.nextep = wminfo.epsd = gameepisode -1;
|
||||
wminfo.last = gamemap -1;
|
||||
|
||||
wminfo.lastmapinfo = gamemapinfo;
|
||||
@ -1083,7 +1070,7 @@ static void G_DoCompleted(void)
|
||||
if (gamemapinfo)
|
||||
{
|
||||
const char *next = "";
|
||||
if (gamemapinfo->endpic[0] && (strcmp(gamemapinfo->endpic, "-") != 0) && !gamemapinfo->nointermission)
|
||||
if (gamemapinfo->endpic[0] && (strcmp(gamemapinfo->endpic, "-") != 0) && gamemapinfo->nointermission)
|
||||
{
|
||||
gameaction = ga_victory;
|
||||
return;
|
||||
@ -1107,6 +1094,20 @@ static void G_DoCompleted(void)
|
||||
}
|
||||
}
|
||||
|
||||
if (gamemode != commercial) // kilough 2/7/98
|
||||
switch(gamemap)
|
||||
{
|
||||
case 8:
|
||||
gameaction = ga_victory;
|
||||
return;
|
||||
case 9:
|
||||
for (i=0 ; i<MAXPLAYERS ; i++)
|
||||
players[i].didsecret = true;
|
||||
break;
|
||||
}
|
||||
|
||||
wminfo.didsecret = players[consoleplayer].didsecret;
|
||||
|
||||
// wminfo.next is 0 biased, unlike gamemap
|
||||
if (gamemode == commercial)
|
||||
{
|
||||
@ -2220,6 +2221,31 @@ void G_WorldDone(void)
|
||||
if (secretexit)
|
||||
players[consoleplayer].didsecret = true;
|
||||
|
||||
if (gamemapinfo)
|
||||
{
|
||||
if (gamemapinfo->intertextsecret && secretexit)
|
||||
{
|
||||
if (gamemapinfo->intertextsecret[0] != '-') // '-' means that any default intermission was cleared.
|
||||
F_StartFinale();
|
||||
|
||||
return;
|
||||
}
|
||||
else if (gamemapinfo->intertext && !secretexit)
|
||||
{
|
||||
if (gamemapinfo->intertext[0] != '-') // '-' means that any default intermission was cleared.
|
||||
F_StartFinale();
|
||||
|
||||
return;
|
||||
}
|
||||
else if (gamemapinfo->endpic[0] && (strcmp(gamemapinfo->endpic, "-") != 0))
|
||||
{
|
||||
// game ends without a status screen.
|
||||
gameaction = ga_victory;
|
||||
return;
|
||||
}
|
||||
// if nothing applied, use the defaults.
|
||||
}
|
||||
|
||||
if (gamemode == commercial)
|
||||
{
|
||||
switch (gamemap)
|
||||
|
@ -948,6 +948,26 @@ static boolean snl_pointeron = false;
|
||||
//
|
||||
static void WI_initShowNextLoc(void)
|
||||
{
|
||||
if (gamemapinfo)
|
||||
{
|
||||
if (gamemapinfo->endpic[0])
|
||||
{
|
||||
G_WorldDone();
|
||||
return;
|
||||
}
|
||||
state = ShowNextLoc;
|
||||
|
||||
// episode change
|
||||
if (wbs->epsd != wbs->nextep)
|
||||
{
|
||||
void WI_loadData(void);
|
||||
|
||||
wbs->epsd = wbs->nextep;
|
||||
wbs->last = wbs->next - 1;
|
||||
WI_loadData();
|
||||
}
|
||||
}
|
||||
|
||||
state = ShowNextLoc;
|
||||
acceleratestage = 0;
|
||||
cnt = SHOWNEXTLOCDELAY * TICRATE;
|
||||
@ -1019,6 +1039,13 @@ static void WI_drawShowNextLoc(void)
|
||||
WI_drawOnLnode(wbs->next, yah);
|
||||
}
|
||||
|
||||
if (gamemapinfo != NULL &&
|
||||
gamemapinfo->endpic[0] &&
|
||||
strcmp(gamemapinfo->endpic, "-") != 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// draws which level you are entering..
|
||||
if ( (gamemode != commercial)
|
||||
|| wbs->next != 30) // check for MAP30 end game
|
||||
@ -1894,7 +1921,7 @@ void WI_DrawBackground(void)
|
||||
// Args: none
|
||||
// Returns: void
|
||||
//
|
||||
static void WI_loadData(void)
|
||||
void WI_loadData(void)
|
||||
{
|
||||
int i,j;
|
||||
char name[32];
|
||||
|
Loading…
x
Reference in New Issue
Block a user