mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 23:02:08 +00:00
- made the sinmple options menu switchable.
Also ensure that custom mods pick up the simple version if enabled.
This commit is contained in:
parent
d0f9ccb09a
commit
54f85d4caa
4 changed files with 19 additions and 4 deletions
|
@ -725,6 +725,8 @@ xx(Loadgamemenu)
|
||||||
xx(Savegamemenu)
|
xx(Savegamemenu)
|
||||||
xx(Readthismenu)
|
xx(Readthismenu)
|
||||||
xx(Optionsmenu)
|
xx(Optionsmenu)
|
||||||
|
xx(OptionsmenuSimple)
|
||||||
|
xx(OptionsmenuFull)
|
||||||
xx(Quitmenu)
|
xx(Quitmenu)
|
||||||
xx(Savemenu)
|
xx(Savemenu)
|
||||||
xx(Playermenu)
|
xx(Playermenu)
|
||||||
|
|
|
@ -71,6 +71,8 @@ EXTERN_CVAR(Bool, saveloadconfirmation) // [mxd]
|
||||||
EXTERN_CVAR(Bool, quicksaverotation)
|
EXTERN_CVAR(Bool, quicksaverotation)
|
||||||
EXTERN_CVAR(Bool, show_messages)
|
EXTERN_CVAR(Bool, show_messages)
|
||||||
|
|
||||||
|
CVAR(Bool, m_simpleoptions, true, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
|
||||||
|
|
||||||
typedef void(*hfunc)();
|
typedef void(*hfunc)();
|
||||||
DMenu* CreateMessageBoxMenu(DMenu* parent, const char* message, int messagemode, bool playsound, FName action = NAME_None, hfunc handler = nullptr);
|
DMenu* CreateMessageBoxMenu(DMenu* parent, const char* message, int messagemode, bool playsound, FName action = NAME_None, hfunc handler = nullptr);
|
||||||
bool OkForLocalization(FTextureID texnum, const char* substitute);
|
bool OkForLocalization(FTextureID texnum, const char* substitute);
|
||||||
|
@ -189,6 +191,15 @@ bool M_SetSpecialMenu(FName& menu, int param)
|
||||||
case NAME_Playermenu:
|
case NAME_Playermenu:
|
||||||
menu = NAME_NewPlayerMenu; // redirect the old player menu to the new one.
|
menu = NAME_NewPlayerMenu; // redirect the old player menu to the new one.
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case NAME_Optionsmenu:
|
||||||
|
if (m_simpleoptions) menu = NAME_OptionsmenuSimple;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case NAME_OptionsmenuFull:
|
||||||
|
menu = NAME_Optionsmenu;
|
||||||
|
break;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
DMenuDescriptor** desc = MenuDescriptors.CheckKey(menu);
|
DMenuDescriptor** desc = MenuDescriptors.CheckKey(menu);
|
||||||
|
|
|
@ -14,7 +14,7 @@ OptionMenu "OptionsMenuSimple" protected
|
||||||
StaticText " "
|
StaticText " "
|
||||||
Submenu "$OS_TITLE", "os_Menu"
|
Submenu "$OS_TITLE", "os_Menu"
|
||||||
StaticText " "
|
StaticText " "
|
||||||
Submenu "$OMS_OLDGZDOOM", "OptionsMenu"
|
Submenu "$OPTMNU_FULLOPTIONS", "OptionsMenuFull"
|
||||||
StaticText " "
|
StaticText " "
|
||||||
SafeCommand "$OPTMNU_DEFAULTS", "reset2defaults"
|
SafeCommand "$OPTMNU_DEFAULTS", "reset2defaults"
|
||||||
SafeCommand "$OPTMNU_RESETTOSAVED", "reset2saved"
|
SafeCommand "$OPTMNU_RESETTOSAVED", "reset2saved"
|
||||||
|
|
|
@ -78,11 +78,11 @@ LISTMENU "MainMenu"
|
||||||
{
|
{
|
||||||
PatchItem "M_LOADG", "l", "LoadGameMenu", 0
|
PatchItem "M_LOADG", "l", "LoadGameMenu", 0
|
||||||
PatchItem "M_SAVEG", "s", "SaveGameMenu",0
|
PatchItem "M_SAVEG", "s", "SaveGameMenu",0
|
||||||
PatchItem "M_OPTION","o", "OptionsMenuSimple", 0
|
PatchItem "M_OPTION","o", "OptionsMenu", 0
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
PatchItem "M_OPTION","o", "OptionsMenuSimple", 0
|
PatchItem "M_OPTION","o", "OptionsMenu", 0
|
||||||
PatchItem "M_LOADG", "l", "LoadGameMenu", 0
|
PatchItem "M_LOADG", "l", "LoadGameMenu", 0
|
||||||
PatchItem "M_SAVEG", "s", "SaveGameMenu", 0
|
PatchItem "M_SAVEG", "s", "SaveGameMenu", 0
|
||||||
}
|
}
|
||||||
|
@ -96,7 +96,7 @@ LISTMENU "MainMenu"
|
||||||
IfGame(Heretic, Hexen)
|
IfGame(Heretic, Hexen)
|
||||||
{
|
{
|
||||||
TextItem "$MNU_NEWGAME", "n", "PlayerclassMenu"
|
TextItem "$MNU_NEWGAME", "n", "PlayerclassMenu"
|
||||||
TextItem "$MNU_OPTIONS", "o", "OptionsMenuSimple"
|
TextItem "$MNU_OPTIONS", "o", "OptionsMenu"
|
||||||
TextItem "$MNU_GAMEFILES", "g", "GameFilesMenu"
|
TextItem "$MNU_GAMEFILES", "g", "GameFilesMenu"
|
||||||
TextItem "$MNU_INFO", "i", "ReadThisMenu"
|
TextItem "$MNU_INFO", "i", "ReadThisMenu"
|
||||||
TextItem "$MNU_QUITGAME", "q", "QuitMenu"
|
TextItem "$MNU_QUITGAME", "q", "QuitMenu"
|
||||||
|
@ -382,6 +382,8 @@ OptionMenu "OptionsMenu" protected
|
||||||
Submenu "$OPTMNU_VIDEO", "VideoModeMenu"
|
Submenu "$OPTMNU_VIDEO", "VideoModeMenu"
|
||||||
StaticText " "
|
StaticText " "
|
||||||
Submenu "$OS_TITLE", "os_Menu"
|
Submenu "$OS_TITLE", "os_Menu"
|
||||||
|
Option "$OPTMNU_SIMPLEON", "m_simpleoptions", "OnOff"
|
||||||
|
|
||||||
StaticText " "
|
StaticText " "
|
||||||
SafeCommand "$OPTMNU_DEFAULTS", "reset2defaults"
|
SafeCommand "$OPTMNU_DEFAULTS", "reset2defaults"
|
||||||
SafeCommand "$OPTMNU_RESETTOSAVED", "reset2saved"
|
SafeCommand "$OPTMNU_RESETTOSAVED", "reset2saved"
|
||||||
|
|
Loading…
Reference in a new issue