Use M_SetupNextMenu to actually set up the Sound Options menu "properly" instead of the old hacks.

If you wanted the game to reset the item selected to the top option like before though, I left a line commented out that would do that for you. Unlike the old item = 0 way, it would automatically be corrected for headers and other spaces (thus kind of future-proofing this code)
This commit is contained in:
Monster Iestyn 2019-07-08 21:17:40 +01:00
parent 29bf89824f
commit 4da108748b
1 changed files with 3 additions and 2 deletions

View File

@ -2953,8 +2953,9 @@ boolean M_Responder(event_t *ev)
return true;
M_StartControlPanel();
M_Options(0);
currentMenu = &OP_SoundOptionsDef;
itemOn = 0;
// Uncomment the below if you want the menu to reset to the top each time like before. M_SetupNextMenu will fix it automatically.
//OP_SoundOptionsDef.lastOn = 0;
M_SetupNextMenu(&OP_SoundOptionsDef);
return true;
case KEY_F5: // Video Mode