Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
SCR_AIDecoTestIsAgentInGroup.c
Go to the documentation of this file.
1
class
SCR_AIDecoTestIsAgentInGroup
:
DecoratorTestScripted
2
{
3
protected
override
bool
TestFunction
(AIAgent agent,
IEntity
controlled)
4
{
5
if
(!controlled)
6
return
false
;
7
AIGroup group = AIGroup.Cast(agent);
8
if
(!group)
9
return
false
;
10
AIControlComponent contr = AIControlComponent.Cast(controlled.
FindComponent
(AIControlComponent));
11
if
(!contr)
12
return
false
;
13
AIAgent agToTest = contr.GetAIAgent();
14
if
(!group || !agToTest)
15
return
false
;
16
17
array<AIAgent> agents = {};
18
group.GetAgents(agents);
19
return
agents.Contains(agToTest);
20
}
21
};
DecoratorTestScripted
Definition
DecoratorTestScripted.c:13
IEntity
Definition
IEntity.c:13
IEntity::FindComponent
proto external Managed FindComponent(typename typeName)
SCR_AIDecoTestIsAgentInGroup
Definition
SCR_AIDecoTestIsAgentInGroup.c:2
SCR_AIDecoTestIsAgentInGroup::TestFunction
override bool TestFunction(AIAgent agent, IEntity controlled)
Definition
SCR_AIDecoTestIsAgentInGroup.c:3
scripts
Game
AI
ScriptedNodes
Groups
SCR_AIDecoTestIsAgentInGroup.c
Generated by
1.17.0