mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-23 03:52:12 -04:00
Remove conditional disabling of HUD menu items (#1490)
* Remove conditional disabling of HUD menu items Crispy HUD shares the "Colored Numbers" and "Gray Percent Sign" settings with the vanilla status bar, so they should always be available to toggle. * Remove the rest of the conditional disabling
This commit is contained in:
parent
dfb4c9ae11
commit
1cb799331b
33
src/m_menu.c
33
src/m_menu.c
@ -1535,8 +1535,6 @@ static void M_ChangeMessages(int choice)
|
|||||||
// hud_displayed is toggled by + or = in fullscreen
|
// hud_displayed is toggled by + or = in fullscreen
|
||||||
// hud_displayed is cleared by -
|
// hud_displayed is cleared by -
|
||||||
|
|
||||||
static void M_UpdateHUDItems(void);
|
|
||||||
|
|
||||||
static void M_SizeDisplay(int choice)
|
static void M_SizeDisplay(int choice)
|
||||||
{
|
{
|
||||||
switch(choice)
|
switch(choice)
|
||||||
@ -1563,7 +1561,6 @@ static void M_SizeDisplay(int choice)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
R_SetViewSize (screenblocks /*, detailLevel obsolete -- killough */);
|
R_SetViewSize (screenblocks /*, detailLevel obsolete -- killough */);
|
||||||
M_UpdateHUDItems();
|
|
||||||
saved_screenblocks = screenblocks;
|
saved_screenblocks = screenblocks;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3197,32 +3194,9 @@ enum {
|
|||||||
stat1_smooth,
|
stat1_smooth,
|
||||||
};
|
};
|
||||||
|
|
||||||
static void M_UpdateHUDAppearanceItems(void)
|
|
||||||
{
|
|
||||||
const boolean prefer_red = (screenblocks != 11 && !sts_colored_numbers);
|
|
||||||
|
|
||||||
DISABLE_ITEM(prefer_red, stat_settings1[stat1_backpack]);
|
|
||||||
DISABLE_ITEM(prefer_red, stat_settings1[stat1_armortype]);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void M_UpdateHUDItems(void)
|
|
||||||
{
|
|
||||||
const boolean full_hud = (screenblocks == 11);
|
|
||||||
|
|
||||||
DISABLE_ITEM(full_hud, stat_settings1[stat1_title1]);
|
|
||||||
DISABLE_ITEM(full_hud, stat_settings1[stat1_colornum]);
|
|
||||||
DISABLE_ITEM(full_hud, stat_settings1[stat1_graypcnt]);
|
|
||||||
DISABLE_ITEM(full_hud, stat_settings1[stat1_solid]);
|
|
||||||
DISABLE_ITEM(!full_hud, stat_settings1[stat1_title2]);
|
|
||||||
DISABLE_ITEM(!full_hud, stat_settings1[stat1_type]);
|
|
||||||
DISABLE_ITEM(!full_hud, stat_settings1[stat1_mode]);
|
|
||||||
|
|
||||||
M_UpdateHUDAppearanceItems();
|
|
||||||
}
|
|
||||||
|
|
||||||
static void M_SizeDisplayAlt(void)
|
static void M_SizeDisplayAlt(void)
|
||||||
{
|
{
|
||||||
boolean choice = -1;
|
int choice = -1;
|
||||||
|
|
||||||
if (screenblocks > saved_screenblocks)
|
if (screenblocks > saved_screenblocks)
|
||||||
{
|
{
|
||||||
@ -3241,7 +3215,6 @@ static void M_SizeDisplayAlt(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
hud_displayed = (screenblocks == 11);
|
hud_displayed = (screenblocks == 11);
|
||||||
M_UpdateHUDItems();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static const char *screensize_strings[] = {
|
static const char *screensize_strings[] = {
|
||||||
@ -3272,7 +3245,7 @@ setup_menu_t stat_settings1[] = // Status Bar and HUD Settings screen
|
|||||||
{"", S_SKIP, m_null, H_X, M_THRM_SPC},
|
{"", S_SKIP, m_null, H_X, M_THRM_SPC},
|
||||||
|
|
||||||
{"Status Bar", S_SKIP|S_TITLE, m_null, H_X, M_SPC},
|
{"Status Bar", S_SKIP|S_TITLE, m_null, H_X, M_SPC},
|
||||||
{"Colored Numbers", S_YESNO|S_COSMETIC, m_null, H_X, M_SPC, {"sts_colored_numbers"}, 0, M_UpdateHUDAppearanceItems},
|
{"Colored Numbers", S_YESNO|S_COSMETIC, m_null, H_X, M_SPC, {"sts_colored_numbers"}},
|
||||||
{"Gray Percent Sign", S_YESNO|S_COSMETIC, m_null, H_X, M_SPC, {"sts_pct_always_gray"}},
|
{"Gray Percent Sign", S_YESNO|S_COSMETIC, m_null, H_X, M_SPC, {"sts_pct_always_gray"}},
|
||||||
{"Solid Background Color", S_YESNO, m_null, H_X, M_SPC, {"st_solidbackground"}},
|
{"Solid Background Color", S_YESNO, m_null, H_X, M_SPC, {"st_solidbackground"}},
|
||||||
|
|
||||||
@ -5122,7 +5095,6 @@ static boolean M_ShortcutResponder(void)
|
|||||||
hud_displayed = 1; //jff 3/3/98 turn hud on
|
hud_displayed = 1; //jff 3/3/98 turn hud on
|
||||||
hud_active = (hud_active + 1) % 3; // cycle hud_active
|
hud_active = (hud_active + 1) % 3; // cycle hud_active
|
||||||
HU_disable_all_widgets();
|
HU_disable_all_widgets();
|
||||||
M_UpdateHUDItems();
|
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -7215,7 +7187,6 @@ void M_ResetSetupMenu(void)
|
|||||||
M_UpdateCrosshairItems();
|
M_UpdateCrosshairItems();
|
||||||
M_UpdateCenteredWeaponItem();
|
M_UpdateCenteredWeaponItem();
|
||||||
M_UpdateAdvancedSoundItems();
|
M_UpdateAdvancedSoundItems();
|
||||||
M_UpdateHUDItems();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void M_ResetSetupMenuVideo(void)
|
void M_ResetSetupMenuVideo(void)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user