58 Widget activeIdentityHolder, inactiveIdentityHolder;
63 activeIdentityHolder = characterIdentityHolder;
64 inactiveIdentityHolder = genericIdentityHolder;
69 activeIdentityHolder = genericIdentityHolder;
70 inactiveIdentityHolder = characterIdentityHolder;
73 if (inactiveIdentityHolder)
74 inactiveIdentityHolder.SetVisible(
false);
77 if (!activeIdentityHolder)
97 nameText.SetText(playerName);
99 nameSet = !playerName.IsEmpty();
104 IEntity identityOwner = linkedIdentity.GetOwner();
107 int ownerPlayerId =
GetGame().GetPlayerManager().GetPlayerIdFromControlledEntity(identityOwner);
108 if (ownerPlayerId > 0)
112 nameText.SetText(ownerName);
113 nameSet = !ownerName.IsEmpty();
122 SCR_CharacterIdentityComponent characterIdentity = SCR_CharacterIdentityComponent.Cast(linkedIdentity.GetOwner().FindComponent(SCR_CharacterIdentityComponent));
123 if (characterIdentity)
125 string format, fistName, alias, surName;
126 characterIdentity.GetFormattedFullName(format, fistName, alias, surName);
128 nameText.SetTextFormat(format, fistName, alias, surName);
146 nameHolder.SetVisible(
false);
153 bool showCallsign =
true;
155 FactionAffiliationComponent factionAffiliation = FactionAffiliationComponent.Cast(linkedIdentity.GetOwner().FindComponent(FactionAffiliationComponent));
156 if (factionAffiliation)
165 if (showCallsign && callsignText)
170 string company, platoon, squad, character, format;
172 if (callsignComp.
GetCallsignNames(company, platoon, squad, character, format))
173 callsignText.SetTextFormat(format, company, platoon, squad, character);
175 callsignHolder.SetVisible(
false);
180 callsignHolder.SetVisible(
false);
185 callsignHolder.SetVisible(
false);
194 if (identityManager && creationDateText)
196 string format, day, month, year, age;
199 creationDateText.SetTextFormat(format, day, month, year, age);
205 birthDayWidget.SetVisible(
true);
210 creationDateText.SetVisible(
false);
216 if (placeOfCreationText)
221 if (extendedIdentity)
224 if (uiInfo && !uiInfo.GetName().IsEmpty())
225 uiInfo.SetNameTo(placeOfCreationText);
227 placeOfCreationText.SetVisible(
false);
231 if ((!creationDateText || !creationDateText.IsVisible()) && (!placeOfCreationText || !placeOfCreationText.IsVisible()))
232 creationHolder.SetVisible(
false);
240 if (identityManager && bloodTypeText)
243 if (extendedIdentity)
247 uiInfo.SetNameTo(bloodTypeText);
249 bloodTypeHolder.SetVisible(
false);
253 bloodTypeHolder.SetVisible(
false);
258 bloodTypeHolder.SetVisible(
false);
269 if (bioHolderText && !identityBio.
GetBioText().IsEmpty())
271 bioHolderText.SetText(identityBio.
GetBioText());
275 bioHolder.SetVisible(
false);
280 bioHolder.SetVisible(
false);
286 if (ValuableIntelHolder)
287 ValuableIntelHolder.SetVisible(identityItemComponent.HasValuableIntel());