From bc009634e500f3dc89056bbca06f66fda3a9b739 Mon Sep 17 00:00:00 2001 From: teinarss Date: Wed, 14 Nov 2018 21:46:23 +0100 Subject: [PATCH] Show team/spawn widget after admin transfer. --- OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyUtils.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyUtils.cs b/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyUtils.cs index 7405a88084..78289addd6 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyUtils.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/Lobby/LobbyUtils.cs @@ -525,7 +525,9 @@ namespace OpenRA.Mods.Common.Widgets.Logic public static void SetupTeamWidget(Widget parent, Session.Slot s, Session.Client c) { - parent.Get("TEAM").GetText = () => (c.Team == 0) ? "-" : c.Team.ToString(); + var team = parent.Get("TEAM"); + team.IsVisible = () => true; + team.GetText = () => (c.Team == 0) ? "-" : c.Team.ToString(); HideChildWidget(parent, "TEAM_DROPDOWN"); } @@ -548,7 +550,9 @@ namespace OpenRA.Mods.Common.Widgets.Logic public static void SetupSpawnWidget(Widget parent, Session.Slot s, Session.Client c) { - parent.Get("SPAWN").GetText = () => (c.SpawnPoint == 0) ? "-" : Convert.ToChar('A' - 1 + c.SpawnPoint).ToString(); + var spawn = parent.Get("SPAWN"); + spawn.IsVisible = () => true; + spawn.GetText = () => (c.SpawnPoint == 0) ? "-" : Convert.ToChar('A' - 1 + c.SpawnPoint).ToString(); HideChildWidget(parent, "SPAWN_DROPDOWN"); }