mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-22 10:02:01 +00:00
Add MBF_CANTRESTORE
Replaces hardcoded exception to restoreMenu
This commit is contained in:
parent
f0fbd07804
commit
340b1914d2
3 changed files with 6 additions and 5 deletions
|
|
@ -140,6 +140,7 @@ typedef enum
|
|||
MBF_SOUNDLESS = 1<<1, // do not play base menu sounds
|
||||
MBF_NOLOOPENTRIES = 1<<2, // do not loop M_NextOpt/M_PrevOpt
|
||||
MBF_DRAWBGWHILEPLAYING = 1<<3, // run backroutine() outside of GS_MENU
|
||||
MBF_CANTRESTORE = 1<<4, // Do not use in restoreMenu
|
||||
} menubehaviourflags_t;
|
||||
|
||||
struct menuitem_t
|
||||
|
|
|
|||
|
|
@ -662,7 +662,7 @@ boolean M_ConsiderSealedSwapAlert(void)
|
|||
|
||||
void M_ValidateRestoreMenu(void)
|
||||
{
|
||||
if (restoreMenu == NULL || restoreMenu == &MAIN_GonerDef)
|
||||
if (restoreMenu == NULL || (restoreMenu->behaviourflags & MBF_CANTRESTORE))
|
||||
restoreMenu = &MainDef;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ menu_t MAIN_GonerDef = {
|
|||
MAIN_Goner,
|
||||
26, 160,
|
||||
0, sizeof (MAIN_Goner) / sizeof (menuitem_t), // extra2 is final width
|
||||
MBF_UD_LR_FLIPPED,
|
||||
MBF_CANTRESTORE|MBF_UD_LR_FLIPPED,
|
||||
"_GONER",
|
||||
0, 0,
|
||||
M_GonerDrawer,
|
||||
|
|
@ -83,7 +83,7 @@ menu_t MAIN_GonerDef = {
|
|||
M_GonerInputs,
|
||||
};
|
||||
|
||||
menuitem_t MAIN_GonerChoice[] =
|
||||
static menuitem_t MAIN_GonerChoice[] =
|
||||
{
|
||||
{IT_STRING | IT_CALL, "Tails' way",
|
||||
"As a child scientist, Tails has recorded bits\n"
|
||||
|
|
@ -106,14 +106,14 @@ menuitem_t MAIN_GonerChoice[] =
|
|||
NULL, {.routine = M_GonerPlayground}, 0, 0},
|
||||
};
|
||||
|
||||
menu_t MAIN_GonerChoiceDef = {
|
||||
static menu_t MAIN_GonerChoiceDef = {
|
||||
sizeof (MAIN_GonerChoice) / sizeof (menuitem_t),
|
||||
&MAIN_GonerDef,
|
||||
0,
|
||||
MAIN_GonerChoice,
|
||||
26, 160,
|
||||
0, 0,
|
||||
MBF_UD_LR_FLIPPED|MBF_NOLOOPENTRIES,
|
||||
MBF_CANTRESTORE|MBF_UD_LR_FLIPPED|MBF_NOLOOPENTRIES,
|
||||
"_GONER",
|
||||
0, 0,
|
||||
M_GonerChoiceDrawer,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue