From d2e4c2904f695a67674f4a12d1e1135a03c13014 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Sat, 10 Aug 2013 11:45:05 +0200 Subject: [PATCH] fix broken team display in cnc objectives --- OpenRA.Mods.Cnc/Widgets/Logic/CncConquestObjectivesLogic.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/OpenRA.Mods.Cnc/Widgets/Logic/CncConquestObjectivesLogic.cs b/OpenRA.Mods.Cnc/Widgets/Logic/CncConquestObjectivesLogic.cs index d10a55ea9f..5888712a66 100644 --- a/OpenRA.Mods.Cnc/Widgets/Logic/CncConquestObjectivesLogic.cs +++ b/OpenRA.Mods.Cnc/Widgets/Logic/CncConquestObjectivesLogic.cs @@ -58,7 +58,8 @@ namespace OpenRA.Mods.Cnc.Widgets.Logic item.Get("FACTION").GetText = () => pp.Country.Name; var team = item.Get("TEAM"); - team.GetText = () => (pp.PlayerReference.Team == 0) ? "-" : pp.PlayerReference.Team.ToString(); + var teamNumber = world.LobbyInfo.ClientWithIndex(pp.ClientIndex).Team; + team.GetText = () => (teamNumber == 0) ? "-" : teamNumber.ToString(); scrollpanel.AddChild(item); var stats = pp.PlayerActor.TraitOrDefault();