Cleans up some profilemenu state in M_ResetOptions

This would pollute into M_PlayMenuJam and possibly cause it to play whenever
This commit is contained in:
toaster 2025-09-15 21:13:05 +01:00
parent 751934250c
commit e96913bda7
3 changed files with 5 additions and 5 deletions

View file

@ -91,6 +91,8 @@ void M_ResetOptions(void)
// For profiles:
memset(setup_player, 0, sizeof(setup_player));
optionsmenu.profile = NULL;
optionsmenu.profilemenu = false;
optionsmenu.resetprofilemenu = false;
}
void M_InitOptions(INT32 choice)

View file

@ -53,8 +53,7 @@ void M_FirstPickProfile(INT32 c)
{
if (c == MA_YES)
{
M_ResetOptions(); // Reset all options variables otherwise things are gonna go reaaal bad lol.
optionsmenu.profile = NULL; // Make sure to get rid of that, too.
M_ResetOptions(); // Reset all options variables otherwise things are gonna go reaaal bad lol.
PR_ApplyProfile(optionsmenu.profilen, 0);
@ -162,7 +161,7 @@ void M_HandleProfileSelect(INT32 ch)
if (menutransition.tics == 0 && optionsmenu.resetprofile)
{
optionsmenu.profile = NULL; // Make sure to reset that when transitions are done.'
optionsmenu.profile = NULL; // Make sure to reset that when transitions are done.
optionsmenu.resetprofile = false;
}

View file

@ -135,8 +135,7 @@ static void M_ProfileEditExit(void)
}
else
{
M_ResetOptions(); // Reset all options variables otherwise things are gonna go reaaal bad lol.
optionsmenu.profile = NULL; // Make sure to get rid of that, too.
M_ResetOptions(); // Reset all options variables otherwise things are gonna go reaaal bad lol.
}
PR_SaveProfiles(); // save profiles after we do that.