15 [
Attribute(defvalue:
"{16B14338A8911683}UI/layouts/Menus/DeployMenu/WelcomeScreenThreeHorizontalColumns.layout")]
16 protected ResourceName m_sThreeHorizontalColumnsLayout;
19 protected ref SCR_WelcomeScreenBaseContent m_LeftColumn;
22 protected ref SCR_WelcomeScreenBaseContent m_MiddleColumn;
25 protected ref SCR_WelcomeScreenBaseContent m_RightColumn;
27 protected const string WELCOME_CONTENT =
"WelcomeContent";
29 protected const string LEFT_COLUMN =
"LeftColumn";
30 protected const string MIDDLE_COLUMN =
"MiddleColumn";
31 protected const string RIGHT_COLUMN =
"RightColumn";
33 protected const string LEFT_COLUMN_BUTTON =
"LeftColumnButton";
34 protected const string MIDDLE_COLUMN_BUTTON =
"MiddleColumnButton";
35 protected const string RIGHT_COLUMN_BUTTON =
"RightColumnButton";
40 Widget targetColumn = menu.GetRootWidget().FindAnyWidget(
WELCOME_CONTENT);
68 class SCR_WelcomeScreenBaseContent : ScriptAndConfig
71 protected bool m_bIsInteractible;
73 protected string m_sContentName;
82 m_sContentName = column;
88 void ToggleInteractions(
bool enabled);
92 string GetContentName()
94 return m_sContentName;
100 bool GetIsInteractible()
102 return m_bIsInteractible;
108 class SCR_WelcomeScreenMissionObjectivesContent : SCR_WelcomeScreenBaseContent
111 protected string m_sTitleText;
114 protected ref array<ref SCR_WelcomeScreenMissionObjectives> m_aMissionObjectives;
117 protected string m_sBottomTitleText;
119 protected Widget m_wMissionObjectivesWidget;
120 protected int m_iObjectivesCount;
122 [
Attribute(defvalue:
"{ECDF3386111C93B6}UI/layouts/Menus/DeployMenu/WelcomeScreenMissionObjectivesColumn.layout")]
123 protected ResourceName m_sMissionObjectivesColumnLayout;
125 [
Attribute(defvalue:
"{B03D5FCC04D25B95}UI/layouts/Menus/DeployMenu/WelcomeScreenMissionObjective.layout")]
126 protected ResourceName m_sMissionObjectiveLayout;
131 m_sContentName = column;
133 if (!m_aMissionObjectives)
136 m_iObjectivesCount = m_aMissionObjectives.Count();
137 Widget targetColumn = menu.GetRootWidget().FindAnyWidget(column);
141 m_wMissionObjectivesWidget =
GetGame().GetWorkspace().CreateWidgets(m_sMissionObjectivesColumnLayout, targetColumn);
142 if (!m_wMissionObjectivesWidget)
145 Widget missionObjectivesContent = m_wMissionObjectivesWidget.FindAnyWidget(
"MiddleContentVertical");
146 if (!missionObjectivesContent)
149 FillMissionObjectivesWidget(missionObjectivesContent)
155 protected void FillMissionObjectivesWidget(Widget content)
157 RichTextWidget titleText = RichTextWidget.Cast(m_wMissionObjectivesWidget.FindAnyWidget(
"TitleText"));
159 titleText.SetText(GetTitleText());
161 array<ref SCR_WelcomeScreenMissionObjectives> objectives = {};
162 SCR_WelcomeScreenMissionObjectives objective;
164 objectivesCount = GetMissionObjectives(objectives);
167 if (objectivesCount < 11)
168 cycleCount = objectivesCount;
173 for (
int i = 0; i < cycleCount; ++i)
175 objective = objectives[i];
177 Widget cond =
GetGame().GetWorkspace().CreateWidgets(m_sMissionObjectiveLayout, content);
181 RichTextWidget name = RichTextWidget.Cast(cond.FindAnyWidget(
"ObjectiveText"));
183 name.SetText(objective.GetDescription());
185 ImageWidget icon = ImageWidget.Cast(cond.FindAnyWidget(
"Icon"));
187 icon.LoadImageFromSet(0, objective.GetImageSet(), objective.GetObjectiveQuadName(),
false);
190 RichTextWidget bottomTitleText = RichTextWidget.Cast(m_wMissionObjectivesWidget.FindAnyWidget(
"BottomTitleText"));
191 if (!bottomTitleText)
194 if (objectivesCount < 1)
195 bottomTitleText.SetOpacity(0);
197 bottomTitleText.SetTextFormat(GetBottomTitleText(), objectivesCount);
204 int GetMissionObjectives(out array<ref SCR_WelcomeScreenMissionObjectives> missionObjectives)
206 missionObjectives = m_aMissionObjectives;
208 return m_aMissionObjectives.Count();
213 string GetTitleText()
220 string GetBottomTitleText()
222 return m_sBottomTitleText;
228 class SCR_WelcomeScreenMissionObjectives
230 [
Attribute(
"{88966C7AB9720818}UI/Textures/DeployMenu/Objectives-Briefing/Objectives-briefing.imageset", UIWidgets.ResourcePickerThumbnail,
"Image set for the icons",
params:
"edds")]
231 protected ResourceName m_sObjectiveImageSet;
234 protected string m_sObjectiveQuadName;
243 return m_sObjectiveImageSet;
248 string GetObjectiveQuadName()
250 return m_sObjectiveQuadName;
255 string GetDescription()
264 class SCR_WelcomeScreenDynamicObjectivesContent : SCR_WelcomeScreenBaseContent
267 protected string m_sTitleText;
270 protected ref array<ref SCR_WelcomeScreenDynamicTaskFaction> m_aFactions;
272 [
Attribute(defvalue:
"{0B7DDF77E24F0C63}UI/layouts/Menus/DeployMenu/WelcomeScreenDynamicObjectivesColumn.layout")]
273 protected ResourceName m_sFinishedObjectivesTileLayout;
275 [
Attribute(defvalue:
"{B03D5FCC04D25B95}UI/layouts/Menus/DeployMenu/WelcomeScreenMissionObjective.layout")]
276 protected ResourceName m_sFinishedObjectivesLayout;
278 protected Widget m_wFinishedObjectivesWidget;
279 protected Widget m_wPaginationWidget;
280 protected ButtonWidget m_wColumnButton;
281 protected ref array<SCR_BaseTask> m_aObjectivesToDisplay = {};
282 protected ref array<Widget> m_aDynamicObjectivesWidgets = {};
284 protected int m_iDynamicObjectivesCount;
290 m_sContentName = column;
292 Widget targetTile = menu.GetRootWidget().FindAnyWidget(column);
296 m_wFinishedObjectivesWidget =
GetGame().GetWorkspace().CreateWidgets(m_sFinishedObjectivesTileLayout, targetTile);
297 if (!m_wFinishedObjectivesWidget)
300 Widget finishedObjectivesContent = m_wFinishedObjectivesWidget.FindAnyWidget(
"FinishedObjectivesLayout");
301 if (!finishedObjectivesContent)
304 m_wColumnButton = ButtonWidget.Cast(menu.GetRootWidget().FindAnyWidget(columnButton));
305 if (!m_wColumnButton)
308 FillDynamicObjectivesWidget(finishedObjectivesContent);
314 override void ToggleInteractions(
bool enabled)
316 HandlePagination(enabled);
322 void FillDynamicObjectivesWidget(Widget content)
324 RichTextWidget titleText = RichTextWidget.Cast(m_wFinishedObjectivesWidget.FindAnyWidget(
"TitleText"));
325 titleText.SetText(GetTitleText());
335 m_aObjectivesToDisplay.Clear();
336 taskManager.GetTasks(m_aObjectivesToDisplay);
337 m_iDynamicObjectivesCount = m_aObjectivesToDisplay.Count();
339 foreach (SCR_WelcomeScreenDynamicTaskFaction faction : m_aFactions)
343 if (task.GetTargetFaction() !=
m_FactionManager.GetFactionByKey(faction.GetFactionKey()))
346 faction.AddFactionTask(task);
351 m_aDynamicObjectivesWidgets.Clear();
352 for (
int i = 0; i < 10; ++i)
354 Widget objective =
GetGame().GetWorkspace().CreateWidgets(m_sFinishedObjectivesLayout, content);
355 m_aDynamicObjectivesWidgets.Insert(objective);
364 FlipPage(GetCurrentPage());
366 m_wPaginationWidget = m_wFinishedObjectivesWidget.FindAnyWidget(
"BottomTitleSizeLayout");
367 if (!m_wPaginationWidget)
370 if (m_iDynamicObjectivesCount < 11)
372 m_wPaginationWidget.SetOpacity(0);
376 Widget pages = m_wFinishedObjectivesWidget.FindAnyWidget(
"Pages");
381 if (!pagesVisualised)
384 pagesVisualised.SetItemCount(m_iDynamicObjectivesCount/10);
395 GetGame().GetCallqueue().CallLater(AddTaskCalledLater, 1000,
false, task);
403 foreach (SCR_WelcomeScreenDynamicTaskFaction faction : m_aFactions)
405 if (task.GetTargetFaction() !=
m_FactionManager.GetFactionByKey(faction.GetFactionKey()))
408 faction.AddFactionTask(task);
412 m_aObjectivesToDisplay.Clear();
413 foreach (SCR_WelcomeScreenDynamicTaskFaction faction : m_aFactions)
415 m_aObjectivesToDisplay.InsertAll(faction.GetFactionTasks());
418 m_iDynamicObjectivesCount = m_aObjectivesToDisplay.Count();
420 FlipPage(GetCurrentPage());
428 foreach (SCR_WelcomeScreenDynamicTaskFaction faction : m_aFactions)
430 if (task.GetTargetFaction() !=
m_FactionManager.GetFactionByKey(faction.GetFactionKey()))
433 faction.RemoveFactionTask(task);
437 m_aObjectivesToDisplay.Clear();
438 foreach (SCR_WelcomeScreenDynamicTaskFaction faction : m_aFactions)
440 m_aObjectivesToDisplay.InsertAll(faction.GetFactionTasks());
443 m_iDynamicObjectivesCount = m_aObjectivesToDisplay.Count();
445 FlipPage(GetCurrentPage());
450 protected void InitPagination()
452 Widget previousButtonWidget = m_wFinishedObjectivesWidget.FindAnyWidget(
"PrevButton");
453 if (!previousButtonWidget)
458 previousButton.m_OnClicked.Insert(ButtonClicked);
460 Widget nextButtonWidget = m_wFinishedObjectivesWidget.FindAnyWidget(
"NextButton");
461 if (!nextButtonWidget)
466 nextButton.m_OnClicked.Insert(ButtonClicked);
471 protected void ButtonClicked()
473 GetGame().GetWorkspace().SetFocusedWidget(m_wColumnButton);
479 protected void HandlePagination(
bool enabled =
false)
481 Widget previousButtonWidget = m_wFinishedObjectivesWidget.FindAnyWidget(
"PrevButton");
482 if (!previousButtonWidget)
490 previousButton.m_OnActivated.Insert(PreviousButtonActivated);
492 previousButton.m_OnActivated.Remove(PreviousButtonActivated);
494 Widget nextButtonWidget = m_wFinishedObjectivesWidget.FindAnyWidget(
"NextButton");
495 if (!nextButtonWidget)
503 nextButton.m_OnActivated.Insert(NextButtonActivated);
505 nextButton.m_OnActivated.Remove(NextButtonActivated);
510 protected void PreviousButtonActivated()
512 int currentPage = GetCurrentPage();
517 FlipPage(currentPage);
522 protected void NextButtonActivated()
524 int currentPage = GetCurrentPage();
526 if (currentPage == Math.Ceil(m_iDynamicObjectivesCount/10))
529 FlipPage(currentPage);
535 protected void FlipPage(
int currentPage)
537 for (
int i = 0; i < 10; ++i)
539 if (!m_aDynamicObjectivesWidgets[i])
542 m_aDynamicObjectivesWidgets[i].SetOpacity(1);
543 if (currentPage == 0)
545 if (i < m_iDynamicObjectivesCount)
547 RichTextWidget name = RichTextWidget.Cast(m_aDynamicObjectivesWidgets[i].FindAnyWidget(
"ObjectiveText"));
551 name.SetTextFormat(editorTask.GetTitle(), editorTask.GetLocationName());
552 else if (campaignTask)
553 name.SetTextFormat(campaignTask.GetTitle(), campaignTask.GetBaseNameWithCallsign());
555 name.SetText(m_aObjectivesToDisplay[i].GetTitle());
557 ImageWidget image = ImageWidget.Cast(m_aDynamicObjectivesWidgets[i].FindAnyWidget(
"Background"));
558 image.SetColor(m_aObjectivesToDisplay[i].GetTargetFaction().GetFactionColor());
562 m_aDynamicObjectivesWidgets[i].SetOpacity(0);
567 if ((currentPage * 10) + i < m_iDynamicObjectivesCount)
569 RichTextWidget name = RichTextWidget.Cast(m_aDynamicObjectivesWidgets[i].FindAnyWidget(
"ObjectiveText"));
573 name.SetTextFormat(editorTask.GetTitle(), editorTask.GetLocationName());
574 else if (campaignTask)
575 name.SetTextFormat(campaignTask.GetTitle(), campaignTask.GetBaseNameWithCallsign());
577 name.SetText(m_aObjectivesToDisplay[(currentPage * 10) + i].GetTitle());
579 ImageWidget image = ImageWidget.Cast(m_aDynamicObjectivesWidgets[i].FindAnyWidget(
"Background"));
580 image.SetColor(m_aObjectivesToDisplay[(currentPage * 10) + i].GetTargetFaction().GetFactionColor());
584 m_aDynamicObjectivesWidgets[i].SetOpacity(0);
589 SetCurrentPage(currentPage);
591 if (m_wPaginationWidget)
593 if (m_iDynamicObjectivesCount < 11)
594 m_wPaginationWidget.SetOpacity(0);
596 m_wPaginationWidget.SetOpacity(1);
598 Widget pages = m_wFinishedObjectivesWidget.FindAnyWidget(
"Pages");
603 if (!pagesVisualised)
606 pagesVisualised.SetItemCount(m_iDynamicObjectivesCount/10);
607 pagesVisualised.SetCurrentItem(currentPage);
622 void SetCurrentPage(
int page)
629 string GetTitleText()
637 class SCR_WelcomeScreenDynamicTaskFaction
643 protected ref array<SCR_BaseTask> m_aFactionTasks = {};
647 array<SCR_BaseTask> GetFactionTasks()
649 return m_aFactionTasks;
664 if (!m_aFactionTasks.Contains(task))
665 m_aFactionTasks.Insert(task);
673 m_aFactionTasks.RemoveItem(task);
679 class SCR_WelcomeScreenIntroductionContent : SCR_WelcomeScreenBaseContent
682 protected string m_sTitleText;
685 protected ref array<ref SCR_WelcomeScreenIntroduction> m_aIntroduction;
688 protected int m_iIntroductionCount;
690 [
Attribute(defvalue:
"{49EEED554D68F43A}UI/layouts/Menus/DeployMenu/WelcomeScreenIntroductionColumn.layout")]
691 protected ResourceName m_sIntroductionColumnLayout;
693 protected Widget m_wIntroductionContentWidget;
694 protected ButtonWidget m_wColumnButton;
699 m_sContentName = column;
701 if (!m_aIntroduction)
704 m_iIntroductionCount = m_aIntroduction.Count();
705 Widget targetColumn = menu.GetRootWidget().FindAnyWidget(column);
709 m_wColumnButton = ButtonWidget.Cast(menu.GetRootWidget().FindAnyWidget(columnButton));
710 if (!m_wColumnButton)
713 m_wIntroductionContentWidget =
GetGame().GetWorkspace().CreateWidgets(m_sIntroductionColumnLayout, targetColumn);
714 if (!m_wIntroductionContentWidget)
717 FillIntroductionWidget(targetColumn);
721 override void ToggleInteractions(
bool enabled)
723 HandlePagination(enabled);
729 protected void FillIntroductionWidget(Widget column)
731 RichTextWidget titleTextContent = RichTextWidget.Cast(column.FindAnyWidget(
"TitleText"));
732 if (titleTextContent)
733 titleTextContent.SetText(GetTitleText());
735 array<ref SCR_WelcomeScreenIntroduction> introductionPages = {};
736 int introductionCount = GetIntroduction(introductionPages);
737 if (introductionCount == 0)
740 Widget contentVertical = m_wIntroductionContentWidget.FindAnyWidget(
"ContentVertical");
741 if (!contentVertical)
744 ImageWidget imageWidget = ImageWidget.Cast(contentVertical.FindAnyWidget(
"ImageWidget"));
745 if (imageWidget && introductionPages[0].GetImage())
746 imageWidget.LoadImageTexture(0, introductionPages[0].GetImage(),
false,
false);
748 RichTextWidget titleText = RichTextWidget.Cast(contentVertical.FindAnyWidget(
"TitleText"));
750 titleText.SetText(introductionPages[0].GetTitleText());
752 RichTextWidget descriptionText = RichTextWidget.Cast(contentVertical.FindAnyWidget(
"DescriptionText"));
754 descriptionText.SetText(introductionPages[0].GetDescriptionText());
756 Widget pages = m_wIntroductionContentWidget.FindAnyWidget(
"Pages");
761 if (!pagesVisualised)
764 Widget pagination = m_wIntroductionContentWidget.FindAnyWidget(
"Pagination");
768 if (introductionCount == 1)
770 pagination.SetOpacity(0);
774 pagesVisualised.SetItemCount(introductionCount);
782 protected void InitPagination()
784 Widget previousButtonWidget = m_wIntroductionContentWidget.FindAnyWidget(
"PrevButton");
785 if (!previousButtonWidget)
790 previousButton.m_OnClicked.Insert(ButtonClicked);
792 Widget nextButtonWidget = m_wIntroductionContentWidget.FindAnyWidget(
"NextButton");
793 if (!nextButtonWidget)
798 nextButton.m_OnClicked.Insert(ButtonClicked);
803 protected void ButtonClicked()
805 GetGame().GetWorkspace().SetFocusedWidget(m_wColumnButton);
811 protected void HandlePagination(
bool enabled =
false)
813 Widget previousButtonWidget = m_wIntroductionContentWidget.FindAnyWidget(
"PrevButton");
814 if (!previousButtonWidget)
822 previousButton.m_OnActivated.Insert(PreviousButtonActivated);
824 previousButton.m_OnActivated.Remove(PreviousButtonActivated);
826 Widget nextButtonWidget = m_wIntroductionContentWidget.FindAnyWidget(
"NextButton");
827 if (!nextButtonWidget)
835 nextButton.m_OnActivated.Insert(NextButtonActivated);
837 nextButton.m_OnActivated.Remove(NextButtonActivated);
842 protected void PreviousButtonActivated()
844 int currentPage = GetCurrentPage();
849 FlipPage(currentPage)
854 protected void NextButtonActivated()
856 int currentPage = GetCurrentPage();
858 if (currentPage == m_iIntroductionCount)
861 FlipPage(currentPage)
867 protected void FlipPage(
int currentPage)
869 Widget contentVertical = m_wIntroductionContentWidget.FindAnyWidget(
"ContentVertical");
870 if (!contentVertical)
873 SetCurrentPage(currentPage);
874 SCR_WelcomeScreenIntroduction targetIntroduction = m_aIntroduction[currentPage];
875 if (!targetIntroduction)
878 ImageWidget imageWidget = ImageWidget.Cast(contentVertical.FindAnyWidget(
"ImageWidget"));
879 if (imageWidget && targetIntroduction.GetImage())
880 imageWidget.LoadImageTexture(0, targetIntroduction.GetImage(),
false,
false);
882 RichTextWidget titleText = RichTextWidget.Cast(contentVertical.FindAnyWidget(
"TitleText"));
884 titleText.SetText(targetIntroduction.GetTitleText());
886 RichTextWidget descriptionText = RichTextWidget.Cast(contentVertical.FindAnyWidget(
"DescriptionText"));
888 descriptionText.SetText(targetIntroduction.GetDescriptionText());
890 Widget pages = m_wIntroductionContentWidget.FindAnyWidget(
"Pages");
895 if (!pagesVisualised)
898 pagesVisualised.SetCurrentItem(currentPage);
905 int GetIntroduction(out array<ref SCR_WelcomeScreenIntroduction> introduction)
907 introduction = m_aIntroduction;
909 return m_aIntroduction.Count();
914 string GetTitleText()
930 void SetCurrentPage(
int page)
938 class SCR_WelcomeScreenIntroduction
940 [
Attribute(
"", UIWidgets.ResourcePickerThumbnail,
"Flag icon of this particular faction.",
params:
"edds")]
941 protected ResourceName m_sContentImage;
944 protected string m_sContentTitleText;
947 protected string m_sContentDescriptionText;
951 ResourceName GetImage()
953 return m_sContentImage;
958 string GetTitleText()
960 return m_sContentTitleText;
965 string GetDescriptionText()
967 return m_sContentDescriptionText;
973 class SCR_WelcomeScreenFactionContent : SCR_WelcomeScreenBaseContent
976 protected string m_sTitleText;
979 protected string m_sBottomTitleText;
981 [
Attribute(defvalue:
"{4C4460227BBC5134}UI/layouts/Menus/DeployMenu/WelcomeScreenFactionColumn.layout")]
982 protected ResourceName m_sFactionColumnLayout;
984 [
Attribute(defvalue:
"{68CCF1BD8F7AF86C}UI/layouts/Menus/DeployMenu/WelcomeScreenFaction.layout")]
985 protected ResourceName m_sFactionLayout;
987 protected Widget m_wFactionContentWidget;
988 protected ref array<Widget> m_aFactionWidgets = {};
989 protected ref SCR_SortedArray<SCR_Faction> m_SortedFactions =
new SCR_SortedArray<SCR_Faction>();
994 m_sContentName = column;
996 Widget targetColumn = menu.GetRootWidget().FindAnyWidget(column);
1000 m_wFactionContentWidget =
GetGame().GetWorkspace().CreateWidgets(m_sFactionColumnLayout, targetColumn);
1001 if (!m_wFactionContentWidget)
1009 protected void AddFactionWidget()
1011 RichTextWidget titleTextContent = RichTextWidget.Cast(m_wFactionContentWidget.FindAnyWidget(
"TitleText"));
1012 if (titleTextContent)
1013 titleTextContent.SetText(GetTitleText());
1016 Widget blueforContent = m_wFactionContentWidget.FindAnyWidget(
"Bluefor");
1017 Widget opforContent = m_wFactionContentWidget.FindAnyWidget(
"Opfor");
1018 Widget independentContent = m_wFactionContentWidget.FindAnyWidget(
"Independent");
1019 Widget civilianContent = m_wFactionContentWidget.FindAnyWidget(
"Civilian");
1021 if (!blueforContent)
1025 if (!factionManager)
1028 factionManager.GetOnPlayerFactionCountChanged().Insert(UpdateFactionPlayerCount);
1030 int factionCount = factionManager.GetSortedFactionsList(m_SortedFactions);
1032 for (
int i = 0; i < factionCount; i++)
1034 m_SortedFactions[i].GetOnFactionPlayableChanged().Insert(UpdateFactionPlayability);
1039 if (factionCount < 7)
1040 cycleCount = factionCount;
1045 for (
int i = 0; i < cycleCount; i++)
1048 Color factionColor = m_SortedFactions[i].GetFactionColor();
1049 FillFactionWidget(
SCR_Faction.Cast(m_SortedFactions[i]), blueforContent, factionColor);
1052 RichTextWidget bottomTitleText = RichTextWidget.Cast(m_wFactionContentWidget.FindAnyWidget(
"BottomTitleText"));
1053 if (!bottomTitleText)
1056 if (factionCount < 1)
1057 bottomTitleText.SetOpacity(0);
1059 bottomTitleText.SetTextFormat(GetBottomTitleText(), factionCount);
1067 protected void FillFactionWidget(notnull
SCR_Faction faction, notnull Widget content, Color color)
1069 Widget factionWidget =
GetGame().GetWorkspace().CreateWidgets(m_sFactionLayout, content);
1073 m_aFactionWidgets.Insert(factionWidget);
1075 ImageWidget flag = ImageWidget.Cast(factionWidget.FindAnyWidget(
"FlagImage"));
1077 flag.LoadImageTexture(0, faction.GetFactionFlag(),
false,
false);
1079 ImageWidget side = ImageWidget.Cast(factionWidget.FindAnyWidget(
"SideImage"));
1081 side.SetColor(color);
1083 RichTextWidget name = RichTextWidget.Cast(factionWidget.FindAnyWidget(
"FactionNameText"));
1085 name.SetText(faction.GetFactionName());
1087 ImageWidget bar = ImageWidget.Cast(factionWidget.FindAnyWidget(
"Bar"));
1089 bar.SetVisible(
false);
1091 RichTextWidget playerCount = RichTextWidget.Cast(factionWidget.FindAnyWidget(
"FactionPlayerCount"));
1095 ImageWidget playerIcon = ImageWidget.Cast(factionWidget.FindAnyWidget(
"PlayerIcon"));
1096 if (faction.IsPlayable())
1098 playerCount.SetText((faction.GetPlayerCount()).ToString());
1103 playerIcon.SetVisible(
false);
1105 playerCount.SetText(
"#AR-DeployScreen_NonPlayableFaction");
1113 protected void UpdateFactionPlayerCount(
Faction faction,
int playerCountParam)
1116 if (!factionScripted)
1119 Widget factionWidget = m_aFactionWidgets[m_SortedFactions.Find(factionScripted)];
1123 RichTextWidget playerCount = RichTextWidget.Cast(factionWidget.FindAnyWidget(
"FactionPlayerCount"));
1127 playerCount.SetText((playerCountParam).ToString());
1134 protected void UpdateFactionPlayability(
Faction faction,
bool playable)
1137 if (!factionScripted)
1140 Widget factionWidget = m_aFactionWidgets[m_SortedFactions.Find(factionScripted)];
1144 RichTextWidget playerCount = RichTextWidget.Cast(factionWidget.FindAnyWidget(
"FactionPlayerCount"));
1148 ImageWidget playerIcon = ImageWidget.Cast(factionWidget.FindAnyWidget(
"PlayerIcon"));
1149 if (factionScripted.IsPlayable())
1152 playerIcon.SetVisible(
true);
1154 playerCount.SetText((factionScripted.GetPlayerCount()).ToString());
1159 playerIcon.SetVisible(
false);
1161 playerCount.SetText(
"#AR-DeployScreen_NonPlayableFaction");
1167 string GetTitleText()
1169 return m_sTitleText;
1174 string GetBottomTitleText()
1176 return m_sBottomTitleText;