From efa609d3665a4c9e70ebc52e7fa1a68a3c13a155 Mon Sep 17 00:00:00 2001 From: toaster Date: Fri, 15 Nov 2019 15:58:25 +0000 Subject: [PATCH 1/2] Ending music and associated. * Play the good or bad ending track, instead of perfect silence. * Fade out the credits music over 5 seconds when the credits go to the evaluation (timed to have finished just before the "you unlocked this!" jingle). --- src/f_finale.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/f_finale.c b/src/f_finale.c index 108385adb..d925f4689 100644 --- a/src/f_finale.c +++ b/src/f_finale.c @@ -1385,6 +1385,8 @@ boolean F_CreditResponder(event_t *event) void F_StartGameEvaluation(void) { + S_FadeOutStopMusic(5*MUSICRATE); + // Credits option in secrets menu if (cursaveslot == -1) { @@ -1638,7 +1640,7 @@ void F_StartEnding(void) gameaction = ga_nothing; paused = false; CON_ToggleOff(); - S_StopMusic(); // todo: placeholder + S_StopMusic(); S_StopSounds(); finalecount = -10; // what? this totally isn't a hack. why are you asking? @@ -1719,6 +1721,9 @@ void F_EndingTicker(void) return; } + if (finalecount == -8) + S_ChangeMusicInternal((goodending ? "_endg" : "_endb"), false); + if (goodending && finalecount == INFLECTIONPOINT) // time to swap some assets { endegrk[0] = W_CachePatchName("ENDEGRK2", PU_LEVEL); From fdd681ab720fa894e5bee475bb654c17fa5fb2dc Mon Sep 17 00:00:00 2001 From: toaster Date: Sun, 17 Nov 2019 14:14:38 +0000 Subject: [PATCH 2/2] Since I had to tweak this branch to do the scrapped changing-to-title-music-at-a-different-time thing (since it was too late, and too late is WAY worse than too early): Have the credits music fade out over a shorter time when going to the title screen (vs going to evaluation), as opposed to stopping entirely. --- src/f_finale.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/f_finale.c b/src/f_finale.c index d925f4689..547a9e240 100644 --- a/src/f_finale.c +++ b/src/f_finale.c @@ -1385,15 +1385,16 @@ boolean F_CreditResponder(event_t *event) void F_StartGameEvaluation(void) { - S_FadeOutStopMusic(5*MUSICRATE); - // Credits option in secrets menu if (cursaveslot == -1) { + S_FadeOutStopMusic(2*MUSICRATE); F_StartGameEnd(); return; } + S_FadeOutStopMusic(5*MUSICRATE); + G_SetGamestate(GS_EVALUATION); // Just in case they're open ... somehow @@ -2153,7 +2154,6 @@ void F_StartGameEnd(void) gameaction = ga_nothing; paused = false; CON_ToggleOff(); - S_StopMusic(); S_StopSounds(); // In case menus are still up?!!