Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_DamageStateConfig.c
Go to the documentation of this file.
1 [BaseContainerProps(configRoot: true)]
3 {
4  [Attribute(desc: "An array of all damage states to obtain the Icon and Color")]
5  protected ref array<ref SCR_DamageStateInfo> m_aDamageStateUiInfo;
6 
7  [Attribute(desc: "UI info for Unconscious state")]
8  protected ref SCR_DamageStateUIInfo m_UnconciousStateUiInfo;
9 
10  [Attribute(desc: "UI info for Death state")]
11  protected ref SCR_DamageStateUIInfo m_DeathStateUiInfo;
12 
13  [Attribute(desc: "UI info for Destroyed state")]
14  protected ref SCR_DamageStateUIInfo m_DestroyedStateUiInfo;
15 
16  [Attribute(desc: "UI info for Fractured state")]
17  protected ref SCR_DamageStateUIInfo m_FracturedStateUiInfo;
18 
24  SCR_DamageStateUIInfo GetUiInfo(EDamageType damageType)
25  {
26  foreach(SCR_DamageStateInfo damageStateInfo: m_aDamageStateUiInfo)
27  {
28  if (damageStateInfo.m_eDamageType == damageType)
29  return damageStateInfo.m_UiInfo;
30  }
31 
32  Print(string.Format("'SCR_DamageStateConfig': %1 is not included in 'm_aDamageStateUiInfo' thus cannot get UIinfo", typename.EnumToString(EDamageType, damageType)), LogLevel.WARNING);
33  return null;
34  }
35 
41  int GetDamageStateInfoArray(out notnull array<ref SCR_DamageStateInfo> damageStateInfoArray)
42  {
43  damageStateInfoArray.Clear();
44 
45  foreach(SCR_DamageStateInfo damageStateInfo: m_aDamageStateUiInfo)
46  damageStateInfoArray.Insert(damageStateInfo);
47 
48  return damageStateInfoArray.Count();
49  }
50 
55  SCR_DamageStateUIInfo GetUnconciousStateUiInfo()
56  {
57  return m_UnconciousStateUiInfo;
58  }
59 
64  SCR_DamageStateUIInfo GetDeathStateUiInfo()
65  {
66  return m_DeathStateUiInfo;
67  }
68 
73  SCR_DamageStateUIInfo GetDestroyedStateUiInfo()
74  {
75  return m_DestroyedStateUiInfo;
76  }
77 
82  SCR_DamageStateUIInfo GetFracturedStateUiInfo()
83  {
84  return m_FracturedStateUiInfo;
85  }
86 };
87 
90 {
91  [Attribute(desc: "Damage type associated with UI info", uiwidget: UIWidgets.ComboBox, enums: ParamEnumArray.FromEnum(EDamageType))]
92  EDamageType m_eDamageType;
93 
94  [Attribute(desc: "UI info of damage type, including colors and background images")]
95  ref SCR_DamageStateUIInfo m_UiInfo;
96 };
SCR_DamageStateUIInfo
Definition: SCR_DamageStateUIInfo.c:2
SCR_DamageStateInfo
Definition: SCR_DamageStateConfig.c:89
SCR_BaseContainerCustomTitleEnum
class SCR_CampaignHintStorage SCR_BaseContainerCustomTitleEnum(EHint, "m_eHintId")
Definition: SCR_CampaignHintStorage.c:22
desc
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Definition: SCR_RespawnBriefingComponent.c:17
BaseContainerProps
class SCR_DamageStateConfig BaseContainerProps
SCR_DamageStateConfig
Definition: SCR_DamageStateConfig.c:2
Attribute
typedef Attribute
Post-process effect of scripted camera.
EDamageType
EDamageType
Definition: EDamageType.c:12