mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-17 23:21:22 +00:00
Add emeraldspawndelay for Match "super"
Emeralds will not spawn while players are still enjoying their victory dance now.
This commit is contained in:
parent
c6c4ab7c53
commit
1c1acb9f0e
5 changed files with 9 additions and 7 deletions
|
@ -86,6 +86,7 @@ UINT8 modeattacking = ATTACKING_NONE;
|
|||
boolean disableSpeedAdjust = false;
|
||||
boolean imcontinuing = false;
|
||||
boolean runemeraldmanager = false;
|
||||
UINT16 emeraldspawndelay = 60*TICRATE;
|
||||
|
||||
// menu demo things
|
||||
UINT8 numDemos = 3;
|
||||
|
|
|
@ -241,9 +241,10 @@ void P_DoMatchSuper(player_t *player)
|
|||
return;
|
||||
|
||||
// Got 'em all? Turn "super"!
|
||||
emeraldspawndelay = invulntics + 1;
|
||||
player->powers[pw_emeralds] = 0;
|
||||
player->powers[pw_invulnerability] = invulntics + 1;
|
||||
player->powers[pw_sneakers] = player->powers[pw_invulnerability];
|
||||
player->powers[pw_invulnerability] = emeraldspawndelay;
|
||||
player->powers[pw_sneakers] = emeraldspawndelay;
|
||||
if (P_IsLocalPlayer(player) && !player->powers[pw_super])
|
||||
{
|
||||
S_StopMusic();
|
||||
|
|
|
@ -657,14 +657,12 @@ void P_EmeraldManager(void)
|
|||
else
|
||||
break;
|
||||
|
||||
if (leveltime < TICRATE) // Start of map
|
||||
spawnpoints[j]->threshold = 60*TICRATE + P_Random() * (TICRATE/5);
|
||||
else
|
||||
spawnpoints[j]->threshold = P_Random() * (TICRATE/5);
|
||||
|
||||
spawnpoints[j]->threshold = emeraldspawndelay + P_Random() * (TICRATE/5);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
emeraldspawndelay = 0;
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
@ -444,5 +444,6 @@ void P_EmeraldManager(void);
|
|||
extern mapthing_t *huntemeralds[MAXHUNTEMERALDS];
|
||||
extern INT32 numhuntemeralds;
|
||||
extern boolean runemeraldmanager;
|
||||
extern UINT16 emeraldspawndelay;
|
||||
extern INT32 numstarposts;
|
||||
#endif
|
||||
|
|
|
@ -2015,6 +2015,7 @@ static void P_LevelInitStuff(void)
|
|||
// special stage tokens, emeralds, and ring total
|
||||
tokenbits = 0;
|
||||
runemeraldmanager = false;
|
||||
emeraldspawndelay = 60*TICRATE;
|
||||
nummaprings = 0;
|
||||
|
||||
// emerald hunt
|
||||
|
|
Loading…
Reference in a new issue