Change the conditions for forced retry at end of round

- If modeattacking, never
- If Sealed Star, if the UFO still exists or the emerald hasn't been picked up
This commit is contained in:
toaster 2022-12-31 17:57:22 +00:00
parent 36b1f5f488
commit 44555be704

View file

@ -2915,17 +2915,24 @@ void G_ExitLevel(void)
if (gamestate == GS_LEVEL) if (gamestate == GS_LEVEL)
{ {
UINT8 i; UINT8 i;
boolean youlost = false; boolean doretry = false;
if (gametyperules & GTR_BOSS)
if (modeattacking != ATTACKING_NONE)
;
else if (specialstageinfo.valid == true)
{ {
youlost = true; doretry = (specialstageinfo.ufo != NULL);
}
else if (gametyperules & GTR_BOSS)
{
doretry = true;
for (i = 0; i < MAXPLAYERS; i++) for (i = 0; i < MAXPLAYERS; i++)
{ {
if (playeringame[i] && !players[i].spectator && !players[i].bot) if (playeringame[i] && !players[i].spectator && !players[i].bot)
{ {
if (players[i].bumpers > 0) if (players[i].bumpers > 0)
{ {
youlost = false; doretry = false;
break; break;
} }
} }
@ -2933,10 +2940,10 @@ void G_ExitLevel(void)
} }
else if (grandprixinfo.gp == true && grandprixinfo.eventmode == GPEVENT_NONE) else if (grandprixinfo.gp == true && grandprixinfo.eventmode == GPEVENT_NONE)
{ {
youlost = (grandprixinfo.wonround != true); doretry = (grandprixinfo.wonround != true);
} }
if (youlost) if (doretry)
{ {
// You didn't win... // You didn't win...