diff --git a/src/g_game.c b/src/g_game.c index 3e69e344a..710a40a91 100644 --- a/src/g_game.c +++ b/src/g_game.c @@ -1984,7 +1984,7 @@ void G_Ticker(boolean run) musiccountdown--; if (musiccountdown == 1) { - Music_Play("intermission"); + Music_PlayIntermission(); } else if (musiccountdown == MUSIC_COUNTDOWN_MAX - K_TallyDelay()) { diff --git a/src/menus/extras-challenges.c b/src/menus/extras-challenges.c index 0911e9632..6fe8ac330 100644 --- a/src/menus/extras-challenges.c +++ b/src/menus/extras-challenges.c @@ -47,7 +47,7 @@ menu_t MISC_StatisticsDef = { 280, 185, 0, 0, 0, - "EXTRAS", + "EXSTAT", 98, 0, M_DrawStatistics, M_DrawExtrasBack, @@ -526,7 +526,7 @@ void M_ChallengesTick(void) challengesmenu.chaokeyhold++; UINT32 chaohold_duration = - CHAOHOLD_PADDING + CHAOHOLD_PADDING + ((unlockables[challengesmenu.currentunlock].majorunlock == true) ? CHAOHOLD_MAJOR : CHAOHOLD_STANDARD diff --git a/src/music.cpp b/src/music.cpp index 4ed22d76c..953f20071 100644 --- a/src/music.cpp +++ b/src/music.cpp @@ -216,6 +216,20 @@ void Music_Play(const char* id) } } +void Music_PlayIntermission(void) +{ + // why aren't the ATTACK_ enums declared alongside modeattacking? + if (modeattacking != 0) + { + Music_Remap("intermission", "timent"); + } + else + { + Music_Remap("intermission", "racent"); + } + Music_Play("intermission"); +} + void Music_DelayEnd(const char* id, tic_t duration) { Tune* tune = g_tunes.find(id); diff --git a/src/music.h b/src/music.h index 2265639ea..9661ce056 100644 --- a/src/music.h +++ b/src/music.h @@ -59,6 +59,10 @@ const char *Music_CurrentId(void); // back to the start.) void Music_Play(const char *id); +// Same as Music_Play, but a convenience for remapping intermission +// based on game state. +void Music_PlayIntermission(void); + // Postpone the end of this tune until N tics from now. The // tune should already be playing before calling this. void Music_DelayEnd(const char *id, tic_t duration); diff --git a/src/s_sound.c b/src/s_sound.c index c3cf0a64e..265deef97 100644 --- a/src/s_sound.c +++ b/src/s_sound.c @@ -1217,7 +1217,7 @@ void S_AttemptToRestoreMusic(void) } // FALLTHRU case GS_INTERMISSION: - Music_Play("intermission"); + Music_PlayIntermission(); break; case GS_CEREMONY: Music_Play("level"); diff --git a/src/y_inter.c b/src/y_inter.c index 62c08ee29..26160eb7c 100644 --- a/src/y_inter.c +++ b/src/y_inter.c @@ -2132,7 +2132,9 @@ void Y_StartIntermission(void) G_SetGamestate(GS_INTERMISSION); if (musiccountdown == 0) - Music_Play("intermission"); + { + Music_PlayIntermission(); + } S_ShowMusicCredit(); // Always call