Profile setup music changes

- Plays unconditionally, even while mid-game
- ...except on the Goner Setup, per direct request
This commit is contained in:
toaster 2023-12-18 19:57:50 +00:00
parent 322e4d3447
commit f955c639e8

View file

@ -365,12 +365,25 @@ void M_PlayMenuJam(void)
return;
}
gdmusic_t override = musicstatepermitted ? gamedata->musicstate : 0;
if (Playing() || soundtest.playing)
if (soundtest.playing)
return;
if (M_GameTrulyStarted() == false)
const boolean trulystarted = M_GameTrulyStarted();
const boolean profilemode = (
trulystarted
&& optionsmenu.profilemenu
&& !optionsmenu.resetprofilemenu
);
if (!profilemode && Playing())
{
if (optionsmenu.resetprofilemenu)
Music_Stop("menu");
return;
}
if (!trulystarted)
{
if (M_GonerMusicPlayable() && NotCurrentlyPlaying("_GONER"))
{
@ -381,6 +394,8 @@ void M_PlayMenuJam(void)
return;
}
gdmusic_t override = musicstatepermitted ? gamedata->musicstate : 0;
if (refMenu != NULL && refMenu->music != NULL)
{
if (refMenu->music[0] == '.' && refMenu->music[1] == '\0')
@ -419,7 +434,7 @@ void M_PlayMenuJam(void)
return;
}
if (cv_menujam_update.value)
if (!profilemode && cv_menujam_update.value)
{
CV_AddValue(&cv_menujam, 1);
CV_SetValue(&cv_menujam_update, 0);