Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_NotificationSupportStationHitZoneGroup.c
Go to the documentation of this file.
1
7{
8 [Attribute(desc: "Config to get the correct hitzone group names from. It will always send over one group so it could be that a group contains multiple hitzone groups in the final notification")]
10
11 [Attribute(desc: "Config to get the correct damage intensity string")]
12 protected ref SCR_DamageIntensityHolder m_DamageIntensityHolder;
13
14 [Attribute("0", desc: "If true will get Character name (first, alias and surname) if the entity is a NPC otherwise will get the entity type name eg: Rifleman")]
15 protected bool m_bGetCharacterName;
16
17 //------------------------------------------------------------------------------------------------
19 {
21 {
22 Print("'SCR_NotificationSupportStationHitZoneGroup' notification: '" + typename.EnumToString(ENotification, m_NotificationKey) + "' is missing the HitzoneGroupDataHolder!", LogLevel.ERROR);
23 return string.Empty;
24 }
25
27 {
28 Print("'SCR_NotificationSupportStationHitZoneGroup' notification: '" + typename.EnumToString(ENotification, m_NotificationKey) + "' is missing the DamageIntensityHolder!", LogLevel.ERROR);
29 return string.Empty;
30 }
31
32 int entityID, hitZoneGroup, health;
33 data.GetParams(entityID, hitZoneGroup, health);
34
35 //~ Get Entity name
36 string entityName;
37 data.GetNotificationTextEntries(entityName);
38 if (!GetEditableEntityName(entityID, entityName, m_bGetCharacterName))
39 return string.Empty;
40
41 //~ Get group name(s)
42 string hitZoneGroupString = m_HitZoneGroupNameHolder.GetHitZoneGroupName(hitZoneGroup);
43
44 float healthScaled = health * 0.001;
45 SCR_UIName intensityUIInfo = m_DamageIntensityHolder.GetValidIntensityUIInfo(healthScaled);
46 if (!intensityUIInfo)
47 return string.Empty;
48
49 string hitZoneDamageIntensity = intensityUIInfo.GetName();
50
51 data.SetNotificationTextEntries(entityName, hitZoneGroupString, hitZoneDamageIntensity);
52 return super.GetText(data);
53 }
54}
ENotification
SCR_AIAnimation_Loitering BaseContainerProps
Commanding menu commanding element class.
class SCR_CampaignHintStorage SCR_BaseContainerCustomTitleEnum(EHint, "m_eHintId")
Get all prefabs that have the spawner data
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Holds the name data to show which parts of the vehicle or character the player is healing.
bool GetEditableEntityName(int entityRplID, out string entityName, bool useCharacterName=false)
LocalizedString GetName()
Definition SCR_UIName.c:31
proto void Print(void var, LogLevel level=LogLevel.NORMAL)
Prints content of variable to console/log.
LogLevel
Enum with severity of the logging message.
Definition LogLevel.c:14
SCR_FieldOfViewSettings Attribute