Merge pull request #10297 from Trebgarta/bleed

Observer Shroud Options listing polish #10263
This commit is contained in:
Oliver Brakmann
2015-12-27 17:31:13 +01:00

View File

@@ -62,6 +62,11 @@ namespace OpenRA.Mods.Common.Widgets.Logic
var groups = new Dictionary<string, IEnumerable<CameraOption>>();
combined = new CameraOption(this, world, "All Players", world.Players.First(p => p.InternalName == "Everyone"));
disableShroud = new CameraOption(this, world, "Disable Shroud", null);
if (!limitViews)
groups.Add("Other", new List<CameraOption>() { combined, disableShroud });
teams = world.Players.Where(p => !p.NonCombatant && p.Playable)
.Select(p => new CameraOption(this, p))
.GroupBy(p => (world.LobbyInfo.ClientWithIndex(p.Player.ClientIndex) ?? new Session.Client()).Team)
@@ -74,11 +79,6 @@ namespace OpenRA.Mods.Common.Widgets.Logic
groups.Add(label, t);
}
combined = new CameraOption(this, world, "All Players", world.Players.First(p => p.InternalName == "Everyone"));
disableShroud = new CameraOption(this, world, "Disable Shroud", null);
if (!limitViews)
groups.Add("Other", new List<CameraOption>() { combined, disableShroud });
var shroudSelector = widget.Get<DropDownButtonWidget>("SHROUD_SELECTOR");
shroudSelector.OnMouseDown = _ =>
{