From ff60540fac36f44b52b1882f8aad8c5720bc093d Mon Sep 17 00:00:00 2001 From: Ivaylo Draganov Date: Tue, 22 Dec 2020 21:56:19 +0200 Subject: [PATCH] Add player random faction info in the objectives panel --- OpenRA.Mods.Common/Widgets/Logic/Ingame/GameInfoStatsLogic.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameInfoStatsLogic.cs b/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameInfoStatsLogic.cs index 10e7b06b60..9dad5039c2 100644 --- a/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameInfoStatsLogic.cs +++ b/OpenRA.Mods.Common/Widgets/Logic/Ingame/GameInfoStatsLogic.cs @@ -101,7 +101,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic if (player == null || player.RelationshipWith(pp) == PlayerRelationship.Ally || player.WinState != WinState.Undefined) { flag.GetImageName = () => pp.Faction.InternalName; - item.Get("FACTION").GetText = () => pp.Faction.Name; + var factionName = pp.Faction.Name != pp.DisplayFaction.Name ? "{0} ({1})".F(pp.DisplayFaction.Name, pp.Faction.Name) : pp.Faction.Name; + item.Get("FACTION").GetText = () => factionName; } else {