Replace 'Always show Healthbars' checkbox with dropdown
The player can now cycle between; -Standard: Health and Status bars display only on mouse hover. -Show On Damage: Health shows on damaged actors, Status always shows. -Always Show: Health and Status bars are always displayed.
This commit is contained in:
@@ -275,8 +275,8 @@ namespace OpenRA.Widgets
|
||||
|
||||
World.Selection.Combine(World, newSelection, true, false);
|
||||
}
|
||||
else if (key == Game.Settings.Keys.ToggleStatusBarsKey)
|
||||
return ToggleStatusBars();
|
||||
else if (key == Game.Settings.Keys.CycleStatusBarsKey)
|
||||
return CycleStatusBars();
|
||||
else if (key == Game.Settings.Keys.TogglePixelDoubleKey)
|
||||
return TogglePixelDouble();
|
||||
}
|
||||
@@ -319,9 +319,15 @@ namespace OpenRA.Widgets
|
||||
.SubsetWithHighestSelectionPriority();
|
||||
}
|
||||
|
||||
bool ToggleStatusBars()
|
||||
bool CycleStatusBars()
|
||||
{
|
||||
Game.Settings.Game.AlwaysShowStatusBars ^= true;
|
||||
if (Game.Settings.Game.StatusBars == StatusBarsType.Standard)
|
||||
Game.Settings.Game.StatusBars = StatusBarsType.DamageShow;
|
||||
else if (Game.Settings.Game.StatusBars == StatusBarsType.DamageShow)
|
||||
Game.Settings.Game.StatusBars = StatusBarsType.AlwaysShow;
|
||||
else if (Game.Settings.Game.StatusBars == StatusBarsType.AlwaysShow)
|
||||
Game.Settings.Game.StatusBars = StatusBarsType.Standard;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user