From e0feed7210f06d3f57a657212f09d30986f7d79e Mon Sep 17 00:00:00 2001 From: mazmazz Date: Tue, 18 Sep 2018 23:27:00 -0400 Subject: [PATCH] EndOfLevel: Check player->exiting > 0 && <= TICRATE, fixes start-of-level fading in 2.1 Braces in y_inter.c --- src/p_user.c | 2 +- src/y_inter.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/p_user.c b/src/p_user.c index 1d34ba5f1..ae7bba582 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -8792,7 +8792,7 @@ void P_PlayerThink(player_t *player) // Same check as below, just at 1 second before // so we can fade music if (!exitfadestarted && - player->exiting <= 1*TICRATE && + player->exiting > 0 && player->exiting <= 1*TICRATE && (!multiplayer || gametype == GT_COOP ? !mapheaderinfo[gamemap-1]->musicinterfadeout : true) && // don't fade if we're fading during intermission. follows Y_StartIntermission intertype = int_coop (gametype == GT_RACE || gametype == GT_COMPETITION ? countdown2 == 0 : true) && // don't fade on timeout diff --git a/src/y_inter.c b/src/y_inter.c index 1f4b49ddf..5e9cb7112 100644 --- a/src/y_inter.c +++ b/src/y_inter.c @@ -696,10 +696,12 @@ void Y_Ticker(void) boolean anybonuses = false; if (!intertic) // first time only + { if (mapheaderinfo[gamemap-1]->musicinterfadeout) S_FadeOutStopMusic(mapheaderinfo[gamemap-1]->musicinterfadeout); else S_ChangeMusicInternal("_clear", false); // don't loop it + } if (intertic < TICRATE) // one second pause before tally begins return;