Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_FrequencyTooltipDetail.c
Go to the documentation of this file.
3 {
4  [Attribute("")]
5  protected LocalizedString m_sNoFrequency;
6 
7  protected TextWidget m_Text;
8  protected SCR_GadgetManagerComponent m_GadgetManager;
9 
10  //------------------------------------------------------------------------------------------------
11  override void UpdateDetail(SCR_EditableEntityComponent entity)
12  {
13  set<int> frequencies = new set<int>();
14  SCR_Global.GetFrequencies(m_GadgetManager, frequencies);
15  if (frequencies.IsEmpty())
16  m_Text.SetText(m_sNoFrequency);
17  else
18  m_Text.SetText(SCR_FormatHelper.FormatFrequencies(frequencies));
19  }
20 
21  //------------------------------------------------------------------------------------------------
22  override bool InitDetail(SCR_EditableEntityComponent entity, Widget widget)
23  {
24  m_Text = TextWidget.Cast(widget);
25  if (!m_Text || entity.GetPlayerID() == 0)
26  return false;
27 
28  m_GadgetManager = SCR_GadgetManagerComponent.Cast(entity.GetOwner().FindComponent(SCR_GadgetManagerComponent));
29  return m_GadgetManager != null;
30  }
31 }
SCR_FormatHelper
Definition: SCR_FormatHelper.c:1
SCR_GadgetManagerComponent
Definition: SCR_GadgetManagerComponent.c:138
BaseContainerCustomTitleField
class SCR_KeyBindingFilter BaseContainerCustomTitleField("m_sBindString")
Definition: SCR_KeyBindingMenuConfig.c:113
Attribute
typedef Attribute
Post-process effect of scripted camera.
m_GadgetManager
SCR_GadgetManagerComponent m_GadgetManager
Definition: SCR_GadgetManagerComponent.c:2
SCR_EntityTooltipDetail
Definition: SCR_EntityTooltipDetail.c:2
SCR_EditableEntityComponent
Definition: SCR_EditableEntityComponent.c:13
SCR_Global
Definition: Functions.c:6
LocalizedString
Definition: LocalizedString.c:21
SCR_FrequencyTooltipDetail
Definition: SCR_FrequencyTooltipDetail.c:2
BaseContainerProps
SCR_AIGoalReaction_Follow BaseContainerProps
Handles insects that are supposed to be spawned around selected prefabs defined in prefab names array...
Definition: SCR_AIGoalReaction.c:468