mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 01:01:33 +00:00
Merge branch 'menu-reordering' into 'master'
Menu reordering (also renaming secrets to extras) See merge request STJr/SRB2Internal!511
This commit is contained in:
commit
a24949cfa6
5 changed files with 52 additions and 60 deletions
|
@ -4349,9 +4349,9 @@ static void Command_Isgamemodified_f(void)
|
|||
if (savemoddata)
|
||||
CONS_Printf(M_GetText("modifiedgame is true, but you can save emblem and time data in this mod.\n"));
|
||||
else if (modifiedgame)
|
||||
CONS_Printf(M_GetText("modifiedgame is true, secrets will not be unlocked\n"));
|
||||
CONS_Printf(M_GetText("modifiedgame is true, extras will not be unlocked\n"));
|
||||
else
|
||||
CONS_Printf(M_GetText("modifiedgame is false, you can unlock secrets\n"));
|
||||
CONS_Printf(M_GetText("modifiedgame is false, you can unlock extras\n"));
|
||||
}
|
||||
|
||||
static void Command_Cheats_f(void)
|
||||
|
|
|
@ -8897,7 +8897,7 @@ static const char *const MENUTYPES_LIST[] = {
|
|||
"OP_SCREENSHOTS",
|
||||
"OP_ERASEDATA",
|
||||
|
||||
// Secrets
|
||||
// Extras
|
||||
"SR_MAIN",
|
||||
"SR_PANDORA",
|
||||
"SR_LEVELSELECT",
|
||||
|
|
|
@ -1386,7 +1386,7 @@ boolean F_CreditResponder(event_t *event)
|
|||
|
||||
void F_StartGameEvaluation(void)
|
||||
{
|
||||
// Credits option in secrets menu
|
||||
// Credits option in extras menu
|
||||
if (cursaveslot == -1)
|
||||
{
|
||||
S_FadeOutStopMusic(2*MUSICRATE);
|
||||
|
@ -1541,9 +1541,9 @@ void F_GameEvaluationDrawer(void)
|
|||
}
|
||||
}
|
||||
else if (netgame)
|
||||
V_DrawString(8, 96, V_YELLOWMAP, "Prizes only\nawarded in\nsingle player!");
|
||||
V_DrawString(8, 96, V_YELLOWMAP, "Multiplayer games\ncan't unlock\nextras!");
|
||||
else
|
||||
V_DrawString(8, 96, V_YELLOWMAP, "Prizes not\nawarded in\nmodified games!");
|
||||
V_DrawString(8, 96, V_YELLOWMAP, "Modified games\ncan't unlock\nextras!");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -1590,7 +1590,7 @@ void F_GameEvaluationTicker(void)
|
|||
{
|
||||
HU_SetCEchoFlags(V_YELLOWMAP|V_RETURN8);
|
||||
HU_SetCEchoDuration(6);
|
||||
HU_DoCEcho("\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Prizes only awarded in singleplayer!");
|
||||
HU_DoCEcho("\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Multiplayer games can't unlock extras!");
|
||||
S_StartSound(NULL, sfx_s3k68);
|
||||
}
|
||||
else if (!modifiedgame || savemoddata)
|
||||
|
@ -1612,7 +1612,7 @@ void F_GameEvaluationTicker(void)
|
|||
{
|
||||
HU_SetCEchoFlags(V_YELLOWMAP|V_RETURN8);
|
||||
HU_SetCEchoDuration(6);
|
||||
HU_DoCEcho("\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Prizes not awarded in modified games!");
|
||||
HU_DoCEcho("\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Modified games can't unlock extras!");
|
||||
S_StartSound(NULL, sfx_s3k68);
|
||||
}
|
||||
}
|
||||
|
|
94
src/m_menu.c
94
src/m_menu.c
|
@ -312,9 +312,7 @@ menu_t OP_VideoOptionsDef, OP_VideoModeDef, OP_ColorOptionsDef;
|
|||
menu_t OP_OpenGLOptionsDef, OP_OpenGLFogDef, OP_OpenGLColorDef;
|
||||
#endif
|
||||
menu_t OP_SoundOptionsDef;
|
||||
#ifdef HAVE_MIXERX
|
||||
menu_t OP_SoundAdvancedDef;
|
||||
#endif
|
||||
|
||||
//Misc
|
||||
menu_t OP_DataOptionsDef, OP_ScreenshotOptionsDef, OP_EraseDataDef;
|
||||
|
@ -474,25 +472,25 @@ static consvar_t cv_dummymares = {"dummymares", "Overall", CV_HIDEN|CV_CALL, dum
|
|||
// ---------
|
||||
static menuitem_t MainMenu[] =
|
||||
{
|
||||
{IT_STRING|IT_CALL, NULL, "Secrets", M_SecretsMenu, 76},
|
||||
{IT_STRING|IT_CALL, NULL, "1 player", M_SinglePlayerMenu, 84},
|
||||
{IT_STRING|IT_CALL, NULL, "1 Player", M_SinglePlayerMenu, 76},
|
||||
#ifndef NONET
|
||||
{IT_STRING|IT_SUBMENU, NULL, "multiplayer", &MP_MainDef, 92},
|
||||
{IT_STRING|IT_SUBMENU, NULL, "Multiplayer", &MP_MainDef, 84},
|
||||
#else
|
||||
{IT_STRING|IT_CALL, NULL, "multiplayer", M_StartSplitServerMenu, 92},
|
||||
{IT_STRING|IT_CALL, NULL, "Multiplayer", M_StartSplitServerMenu, 84},
|
||||
#endif
|
||||
{IT_STRING|IT_CALL, NULL, "options", M_Options, 100},
|
||||
{IT_CALL |IT_STRING, NULL, "addons", M_Addons, 108},
|
||||
{IT_STRING|IT_CALL, NULL, "quit game", M_QuitSRB2, 116},
|
||||
{IT_STRING|IT_CALL, NULL, "Extras", M_SecretsMenu, 92},
|
||||
{IT_CALL |IT_STRING, NULL, "Addons", M_Addons, 100},
|
||||
{IT_STRING|IT_CALL, NULL, "Options", M_Options, 108},
|
||||
{IT_STRING|IT_CALL, NULL, "Quit Game", M_QuitSRB2, 116},
|
||||
};
|
||||
|
||||
typedef enum
|
||||
{
|
||||
secrets = 0,
|
||||
singleplr,
|
||||
singleplr = 0,
|
||||
multiplr,
|
||||
options,
|
||||
secrets,
|
||||
addons,
|
||||
options,
|
||||
quitdoom
|
||||
} main_e;
|
||||
|
||||
|
@ -661,7 +659,7 @@ static menuitem_t SR_PandorasBox[] =
|
|||
// Sky Room Custom Unlocks
|
||||
static menuitem_t SR_MainMenu[] =
|
||||
{
|
||||
{IT_STRING|IT_SUBMENU,NULL, "Secrets Checklist", &SR_UnlockChecklistDef, 0},
|
||||
{IT_STRING|IT_SUBMENU,NULL, "Extras Checklist", &SR_UnlockChecklistDef, 0},
|
||||
{IT_DISABLED, NULL, "", NULL, 0}, // Custom1
|
||||
{IT_DISABLED, NULL, "", NULL, 0}, // Custom2
|
||||
{IT_DISABLED, NULL, "", NULL, 0}, // Custom3
|
||||
|
@ -726,19 +724,19 @@ static menuitem_t SR_EmblemHintMenu[] =
|
|||
// Single Player Main
|
||||
static menuitem_t SP_MainMenu[] =
|
||||
{
|
||||
{IT_CALL | IT_STRING, NULL, "Tutorial", M_StartTutorial, 84},
|
||||
{IT_CALL | IT_STRING, NULL, "Start Game", M_LoadGame, 92},
|
||||
{IT_SECRET, NULL, "Record Attack", M_TimeAttack, 100},
|
||||
{IT_SECRET, NULL, "NiGHTS Mode", M_NightsAttack, 108},
|
||||
{IT_CALL | IT_STRING | IT_CALL_NOTMODIFIED, NULL, "Statistics", M_Statistics, 116},
|
||||
{IT_CALL | IT_STRING, NULL, "Start Game", M_LoadGame, 84},
|
||||
{IT_SECRET, NULL, "Record Attack", M_TimeAttack, 92},
|
||||
{IT_SECRET, NULL, "NiGHTS Mode", M_NightsAttack, 100},
|
||||
{IT_CALL | IT_STRING, NULL, "Tutorial", M_StartTutorial, 108},
|
||||
{IT_CALL | IT_STRING | IT_CALL_NOTMODIFIED, NULL, "Statistics", M_Statistics, 116}
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
sptutorial,
|
||||
sploadgame,
|
||||
sprecordattack,
|
||||
spnightsmode,
|
||||
sptutorial,
|
||||
spstatistics
|
||||
};
|
||||
|
||||
|
@ -1348,29 +1346,22 @@ static menuitem_t OP_OpenGLColorMenu[] =
|
|||
static menuitem_t OP_SoundOptionsMenu[] =
|
||||
{
|
||||
{IT_HEADER, NULL, "Game Audio", NULL, 0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Sound Effects", &cv_gamesounds, 6},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "Sound Volume", &cv_soundvolume, 11},
|
||||
{IT_STRING | IT_CVAR, NULL, "Sound Effects", &cv_gamesounds, 12},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "Sound Volume", &cv_soundvolume, 22},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "Digital Music", &cv_gamedigimusic, 21},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "Digital Music Volume", &cv_digmusicvolume, 26},
|
||||
{IT_STRING | IT_CVAR, NULL, "Digital Music", &cv_gamedigimusic, 42},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "Digital Music Volume", &cv_digmusicvolume, 52},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "MIDI Music", &cv_gamemidimusic, 36},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "MIDI Music Volume", &cv_midimusicvolume, 41},
|
||||
{IT_STRING | IT_CVAR, NULL, "MIDI Music", &cv_gamemidimusic, 72},
|
||||
{IT_STRING | IT_CVAR | IT_CV_SLIDER, NULL, "MIDI Music Volume", &cv_midimusicvolume, 82},
|
||||
|
||||
{IT_HEADER, NULL, "Accessibility", NULL, 50},
|
||||
{IT_STRING | IT_CVAR, NULL, "Closed Captioning", &cv_closedcaptioning, 56},
|
||||
{IT_STRING | IT_CVAR, NULL, "Reset Music Upon Dying", &cv_resetmusic, 61},
|
||||
{IT_HEADER, NULL, "Miscellaneous", NULL, 102},
|
||||
{IT_STRING | IT_CVAR, NULL, "Closed Captioning", &cv_closedcaptioning, 114},
|
||||
{IT_STRING | IT_CVAR, NULL, "Reset Music Upon Dying", &cv_resetmusic, 124},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "Play Sound Effects if Unfocused", &cv_playsoundsifunfocused, 71},
|
||||
{IT_STRING | IT_CVAR, NULL, "Play Music if Unfocused", &cv_playmusicifunfocused, 76},
|
||||
|
||||
#ifdef HAVE_MIXERX
|
||||
{IT_STRING | IT_SUBMENU, NULL, "Advanced Settings...", &OP_SoundAdvancedDef, 94},
|
||||
#endif
|
||||
{IT_STRING | IT_SUBMENU, NULL, "Advanced Settings...", &OP_SoundAdvancedDef, 144},
|
||||
};
|
||||
|
||||
#ifdef HAVE_MIXERX
|
||||
|
||||
#ifdef HAVE_OPENMPT
|
||||
#define OPENMPT_MENUOFFSET 32
|
||||
#else
|
||||
|
@ -1386,24 +1377,25 @@ static menuitem_t OP_SoundOptionsMenu[] =
|
|||
static menuitem_t OP_SoundAdvancedMenu[] =
|
||||
{
|
||||
#ifdef HAVE_OPENMPT
|
||||
{IT_HEADER, NULL, "OpenMPT Settings", NULL, 10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Instrument Filter", &cv_modfilter, 22},
|
||||
{IT_HEADER, NULL, "OpenMPT Settings", NULL, 0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Instrument Filter", &cv_modfilter, 12},
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_MIXERX
|
||||
{IT_HEADER, NULL, "MIDI Settings", NULL, OPENMPT_MENUOFFSET+10},
|
||||
{IT_STRING | IT_CVAR, NULL, "MIDI Player", &cv_midiplayer, OPENMPT_MENUOFFSET+22},
|
||||
{IT_STRING | IT_CVAR | IT_CV_STRING, NULL, "FluidSynth Sound Font File", &cv_midisoundfontpath, OPENMPT_MENUOFFSET+34},
|
||||
{IT_STRING | IT_CVAR | IT_CV_STRING, NULL, "TiMidity++ Config Folder", &cv_miditimiditypath, OPENMPT_MENUOFFSET+61},
|
||||
{IT_HEADER, NULL, "MIDI Settings", NULL, OPENMPT_MENUOFFSET},
|
||||
{IT_STRING | IT_CVAR, NULL, "MIDI Player", &cv_midiplayer, OPENMPT_MENUOFFSET+12},
|
||||
{IT_STRING | IT_CVAR | IT_CV_STRING, NULL, "FluidSynth Sound Font File", &cv_midisoundfontpath, OPENMPT_MENUOFFSET+24},
|
||||
{IT_STRING | IT_CVAR | IT_CV_STRING, NULL, "TiMidity++ Config Folder", &cv_miditimiditypath, OPENMPT_MENUOFFSET+51},
|
||||
#endif
|
||||
|
||||
{IT_HEADER, NULL, "Miscellaneous", NULL, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET+10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Let Levels Force Reset Music", &cv_resetmusicbyheader, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET+22},
|
||||
{IT_HEADER, NULL, "Miscellaneous", NULL, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET},
|
||||
{IT_STRING | IT_CVAR, NULL, "Play Sound Effects if Unfocused", &cv_playsoundsifunfocused, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET+12},
|
||||
{IT_STRING | IT_CVAR, NULL, "Play Music if Unfocused", &cv_playmusicifunfocused, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET+22},
|
||||
{IT_STRING | IT_CVAR, NULL, "Let Levels Force Reset Music", &cv_resetmusicbyheader, OPENMPT_MENUOFFSET+MIXERX_MENUOFFSET+32},
|
||||
};
|
||||
|
||||
#undef OPENMPT_MENUOFFSET
|
||||
#undef MIXERX_MENUOFFSET
|
||||
#endif
|
||||
|
||||
static menuitem_t OP_DataOptionsMenu[] =
|
||||
{
|
||||
|
@ -1455,7 +1447,7 @@ enum
|
|||
static menuitem_t OP_EraseDataMenu[] =
|
||||
{
|
||||
{IT_STRING | IT_CALL, NULL, "Erase Record Data", M_EraseData, 10},
|
||||
{IT_STRING | IT_CALL, NULL, "Erase Secrets Data", M_EraseData, 20},
|
||||
{IT_STRING | IT_CALL, NULL, "Erase Extras Data", M_EraseData, 20},
|
||||
|
||||
{IT_STRING | IT_CALL, NULL, "\x85" "Erase ALL Data", M_EraseData, 40},
|
||||
};
|
||||
|
@ -1666,7 +1658,7 @@ menu_t SP_MainDef = //CENTERMENUSTYLE(NULL, SP_MainMenu, &MainDef, 72);
|
|||
SP_MainMenu,
|
||||
M_DrawCenteredMenu,
|
||||
BASEVIDWIDTH/2, 72,
|
||||
1, // start at "Start Game" on first entry
|
||||
0,
|
||||
NULL
|
||||
};
|
||||
|
||||
|
@ -1992,12 +1984,10 @@ menu_t OP_ColorOptionsDef =
|
|||
0,
|
||||
NULL
|
||||
};
|
||||
menu_t OP_SoundOptionsDef = DEFAULTSCROLLMENUSTYLE(
|
||||
menu_t OP_SoundOptionsDef = DEFAULTMENUSTYLE(
|
||||
MN_OP_MAIN + (MN_OP_SOUND << 6),
|
||||
"M_SOUND", OP_SoundOptionsMenu, &OP_MainDef, 30, 30);
|
||||
#ifdef HAVE_MIXERX
|
||||
menu_t OP_SoundAdvancedDef = DEFAULTMENUSTYLE(MN_OP_MAIN + (MN_OP_SOUND << 6), "M_SOUND", OP_SoundAdvancedMenu, &OP_SoundOptionsDef, 30, 30);
|
||||
#endif
|
||||
|
||||
menu_t OP_ServerOptionsDef = DEFAULTSCROLLMENUSTYLE(
|
||||
MN_OP_MAIN + (MN_OP_SERVER << 6),
|
||||
|
@ -3434,6 +3424,8 @@ void M_StartControlPanel(void)
|
|||
if (!Playing())
|
||||
{
|
||||
// Secret menu!
|
||||
MainMenu[singleplr].alphaKey = (M_AnySecretUnlocked()) ? 76 : 84;
|
||||
MainMenu[multiplr].alphaKey = (M_AnySecretUnlocked()) ? 84 : 92;
|
||||
MainMenu[secrets].status = (M_AnySecretUnlocked()) ? (IT_STRING | IT_CALL) : (IT_DISABLED);
|
||||
|
||||
currentMenu = &MainDef;
|
||||
|
@ -10905,7 +10897,7 @@ static void M_EraseData(INT32 choice)
|
|||
if (choice == 0)
|
||||
eschoice = M_GetText("Record Attack data");
|
||||
else if (choice == 1)
|
||||
eschoice = M_GetText("Secrets data");
|
||||
eschoice = M_GetText("Extras data");
|
||||
else
|
||||
eschoice = M_GetText("ALL game data");
|
||||
|
||||
|
|
|
@ -99,7 +99,7 @@ typedef enum
|
|||
MN_OP_SCREENSHOTS,
|
||||
MN_OP_ERASEDATA,
|
||||
|
||||
// Secrets
|
||||
// Extras
|
||||
MN_SR_MAIN,
|
||||
MN_SR_PANDORA,
|
||||
MN_SR_LEVELSELECT,
|
||||
|
|
Loading…
Reference in a new issue