Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_BaseFactionTriggerEntity.c
Go to the documentation of this file.
1[EntityEditorProps(category: "GameScripted/Triggers", description: "")]
5
6class SCR_BaseFactionTriggerEntity : SCR_BaseTriggerEntity
7{
8 [Attribute(desc: "Factions which are used for area control calculation.", category: "Faction Trigger")]
9 protected ref array<FactionKey> m_aOwnerFactionKeys;
10
11 //------------------------------------------------------------------------------------------------
12 void AddOwnerFaction(FactionKey factionKey)
13 {
16
17 m_aOwnerFactionKeys.Insert(factionKey);
18 }
19
20 //------------------------------------------------------------------------------------------------
22 {
23 if (!m_aOwnerFactionKeys || m_aOwnerFactionKeys.IsEmpty() || !IsAlive(ent))
24 return false;
25
26 FactionAffiliationComponent factionAffiliation = FactionAffiliationComponent.Cast(ent.FindComponent(FactionAffiliationComponent));
27 return factionAffiliation && m_aOwnerFactionKeys.Contains(factionAffiliation.GetAffiliatedFaction().GetFactionKey());
28 }
29
30 //------------------------------------------------------------------------------------------------
32 {
33 SetEventMask(EntityEvent.INIT);
34 }
35}
override bool ScriptedEntityFilterForQuery(IEntity ent)
void SCR_BaseFactionTriggerEntity(IEntitySource src, IEntity parent)
enum SCR_ECompassType EntityEditorProps(category:"GameScripted/Gadgets", description:"Compass", color:"0 0 255 255")
Prefab data class for compass component.
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
ref array< string > m_aOwnerFactionKeys
Definition SCR_Task.c:99
proto external Managed FindComponent(typename typeName)
SCR_FieldOfViewSettings Attribute
EntityEvent
Various entity events.
Definition EntityEvent.c:14