Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_CleanSweepArea.c
Go to the documentation of this file.
1 [EntityEditorProps(category: "GameScripted/CleanSweep", description: "This is clean sweep area entity.", color: "0 0 255 255")]
2 class SCR_CleanSweepAreaClass: GenericEntityClass
3 {
4 };
5 
6 //------------------------------------------------------------------------------------------------
8 {
9  [Attribute("400", UIWidgets.EditBox, "How many groups are spawned in the location")]
10  float m_Range;
11 
12  [Attribute("0", UIWidgets.CheckBox, "Can this location be selected in the mission")]
13  bool m_Active;
14 
15  static ref array<SCR_CleanSweepArea> s_aInstances = new array<SCR_CleanSweepArea>;
16 
17  #ifdef WORKBENCH
18  override void _WB_AfterWorldUpdate(float timeSlice)
19  {
20  int color;
21  const int alpha = 128;
22  if (m_Active)
23  color = ARGB(alpha,0,255,0);
24  else
25  color = ARGB(alpha,0, 0, 0);
26 
27  ref auto pShape = Shape.CreateSphere(color, ShapeFlags.ONCE | ShapeFlags.DOUBLESIDE | ShapeFlags.TRANSP, GetOrigin(), m_Range);
28  }
29  #endif
30 
31  void SCR_CleanSweepArea(IEntitySource src, IEntity parent)
32  {
33  if (s_aInstances)
34  s_aInstances.Insert(this);
35  }
36 
37  void ~SCR_CleanSweepArea()
38  {
39  if (s_aInstances)
40  s_aInstances.RemoveItem(this);
41  }
42 };
SCR_CleanSweepAreaClass
Definition: SCR_CleanSweepArea.c:2
EntityEditorProps
enum EQueryType EntityEditorProps(category:"GameScripted/Sound", description:"THIS IS THE SCRIPT DESCRIPTION.", color:"0 0 255 255")
Definition: SCR_AmbientSoundsComponent.c:12
SCR_CleanSweepArea
Definition: SCR_CleanSweepArea.c:7
GenericEntity
SCR_GenericBoxEntityClass GenericEntity
GetOrigin
vector GetOrigin()
Definition: SCR_AIUtilityComponent.c:279
Attribute
typedef Attribute
Post-process effect of scripted camera.
category
params category
Definition: SCR_VehicleDamageManagerComponent.c:180