Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_AIDefendBehavior.c
Go to the documentation of this file.
2 {
3  ref SCR_BTParam<AIWaypoint> m_RelatedWaypoint = new SCR_BTParam<AIWaypoint>(SCR_AIActionTask.WAYPOINT_PORT);
4  ref SCR_BTParam<vector> m_fDefendLocation = new SCR_BTParam<vector>(SCR_AIActionTask.DEFEND_LOCATION_PORT);
5  ref SCR_BTParam<float> m_fDefendAngularRange = new SCR_BTParam<float>(SCR_AIActionTask.ANGULAR_RANGE_PORT);
6 
7  //------------------------------------------------------------------------------------------------------------------------------------------
8  void InitParameters(AIWaypoint relatedWaypoint, vector defendLocation, float defendAngularRange)
9  {
10  m_RelatedWaypoint.Init(this, relatedWaypoint);
11  m_fDefendLocation.Init(this, defendLocation);
12  m_fDefendAngularRange.Init(this, defendAngularRange);
13  }
14 
15  //------------------------------------------------------------------------------------------------------------------------------------------
16  void SCR_AIDefendBehavior(SCR_AIUtilityComponent utility, SCR_AIActivityBase groupActivity, AIWaypoint relatedWaypoint, vector location, float angularRange, float priority = PRIORITY_BEHAVIOR_DEFEND, float priorityLevel = PRIORITY_LEVEL_NORMAL)
17  {
18  m_sBehaviorTree = "AI/BehaviorTrees/Chimera/Soldier/Defend.bt";
19  SetPriority(priority);
20  m_fPriorityLevel.m_Value = priorityLevel;
21  InitParameters(relatedWaypoint, location, angularRange);
22  }
23 
24  //------------------------------------------------------------------------------------------------------------------------------------------
25  override string GetActionDebugInfo()
26  {
27  return this.ToString() + " defending " + m_RelatedWaypoint.ValueToString();
28  }
29 };
SCR_AIDefendBehavior
Definition: SCR_AIDefendBehavior.c:1
m_fPriorityLevel
float m_fPriorityLevel
Definition: SendGoalMessage.c:3
SCR_AIActivityBase
Definition: SCR_AIActivity.c:1
m_fDefendAngularRange
float m_fDefendAngularRange
Definition: SendGoalMessage.c:753
SCR_AIActionTask
Definition: SCR_AIBehaviorTask.c:1
SCR_AIBehaviorBase
Definition: SCR_AIBehavior.c:1