mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-31 05:30:48 +00:00
Merge branch 'mpss-mixnightscountdown' into 'next'
Support LF_MIXNIGHTSCOUNTDOWN for old-style special stages See merge request STJr/SRB2!2291
This commit is contained in:
commit
31367e3e07
1 changed files with 15 additions and 1 deletions
16
src/p_tick.c
16
src/p_tick.c
|
@ -564,6 +564,12 @@ void P_DoTeamscrambling(void)
|
||||||
CV_SetValue(&cv_teamscramble, 0);
|
CV_SetValue(&cv_teamscramble, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//
|
||||||
|
// P_DoSpecialStageStuff()
|
||||||
|
//
|
||||||
|
// For old-style (non-NiGHTS) special stages
|
||||||
|
//
|
||||||
static inline void P_DoSpecialStageStuff(void)
|
static inline void P_DoSpecialStageStuff(void)
|
||||||
{
|
{
|
||||||
boolean stillalive = false;
|
boolean stillalive = false;
|
||||||
|
@ -601,7 +607,15 @@ static inline void P_DoSpecialStageStuff(void)
|
||||||
if (--players[i].nightstime > 6)
|
if (--players[i].nightstime > 6)
|
||||||
{
|
{
|
||||||
if (P_IsLocalPlayer(&players[i]) && oldnightstime > 10*TICRATE && players[i].nightstime <= 10*TICRATE)
|
if (P_IsLocalPlayer(&players[i]) && oldnightstime > 10*TICRATE && players[i].nightstime <= 10*TICRATE)
|
||||||
S_ChangeMusicInternal("_drown", false);
|
{
|
||||||
|
if (mapheaderinfo[gamemap-1]->levelflags & LF_MIXNIGHTSCOUNTDOWN)
|
||||||
|
{
|
||||||
|
S_FadeMusic(0, 10*MUSICRATE);
|
||||||
|
S_StartSound(NULL, sfx_timeup); // that creepy "out of time" music from NiGHTS.
|
||||||
|
}
|
||||||
|
else
|
||||||
|
S_ChangeMusicInternal("_drown", false);
|
||||||
|
}
|
||||||
stillalive = true;
|
stillalive = true;
|
||||||
}
|
}
|
||||||
else if (!players[i].exiting)
|
else if (!players[i].exiting)
|
||||||
|
|
Loading…
Reference in a new issue