81 RegisterNetSyncVariableFloat(
"m_Radius", 0, 0, 2);
82 RegisterNetSyncVariableFloat(
"m_PositiveHeight", 0, 0, 2);
83 RegisterNetSyncVariableFloat(
"m_NegativeHeight", 0, 0, 2);
85 RegisterNetSyncVariableInt(
"m_InnerRings");
86 RegisterNetSyncVariableInt(
"m_InnerSpacing");
87 RegisterNetSyncVariableInt(
"m_OuterRingOffset");
88 RegisterNetSyncVariableInt(
"m_OuterSpacing");
89 RegisterNetSyncVariableInt(
"m_VerticalLayers");
90 RegisterNetSyncVariableInt(
"m_VerticalOffset");
92 RegisterNetSyncVariableInt(
"m_ParticleID");
98 RegisterNetSyncVariableBool(
"m_OuterRingToggle");
109 if (
params.m_ParamName !=
"")
111 if (
params.m_ParamTriggerType !=
"")
114 if (
params.m_ParamRadius > 0)
116 if (
params.m_ParamPosHeight > -1)
118 if (
params.m_ParamNegHeight > -1)
122 if (
params.m_ParamInnerSpace > -1)
126 if (
params.m_ParamOuterSpace > -1)
130 if (
params.m_ParamVertLayers > 0)
132 if (
params.m_ParamVerticalOffset > 0)
139 if (
params.m_ParamPpeRequesterType !=
"")
175 if (!
GetGame().IsDedicatedServer())
225 Error(
"[WARNING] :: [EffectArea PlaceParticles] :: no particle defined, skipping area particle generation");
238 Error(
"[WARNING] :: [EffectArea PlaceParticles] :: Radius of contaminated zone is set to 0, this should not happen");
244 Error(
"[WARNING] :: [EffectArea PlaceParticles] :: Your outerOffset is EQUAL to your Radius, this will result in division by 0");
352 if (
gPM.IsFinishedAllocating())
354 ErrorEx(
string.Format(
"Not enough particles in pool for EffectArea: %1",
m_Name));
370 if (
p.GetOwner() ==
this)
382 return req.GetRequesterIDX();
429 super.EEDelete(parent);
434 player.IncreaseEffectAreaCount();
438 player.DecreaseEffectAreaCount();
int m_ParamVerticalOffset
string m_ParamTriggerType
string m_ParamPpeRequesterType
enum eZoneType m_ParamName
void ParticleManager(ParticleManagerSettings settings)
Constructor (ctor)
Super root of all classes in Enforce script.
ref array< Particle > m_ToxicClouds
void SetupZoneData(EffectAreaParams params)
override bool CanPutIntoHands(EntityAI parent)
int GetRequesterIndex(string type)
void OnPlayerEnterServer(PlayerBase player, EffectTrigger trigger)
void OnPlayerExitServer(PlayerBase player, EffectTrigger trigger)
string m_PPERequesterType
override bool CanBeTargetedByAI(EntityAI ai)
override void EEDelete(EntityAI parent)
void OnParticleAllocation(ParticleManager pm, array< ParticleSource > particles)
override bool CanPutInCargo(EntityAI parent)
void PlaceParticles(vector pos, float radius, int nbRings, int innerSpacing, bool outerToggle, int outerSpacing, int outerOffset, int partId)
override bool DisableVicinityIcon()
void CreateTrigger(vector pos, int radius)
override void OnCEUpdate()
void SetLocalEffects(int aroundPartId, int tinyPartId, int ppeRequesterIdx)
void Init(EffectArea area, int priority)
Legacy way of using particles in the game.
static const int CONTAMINATED_AREA_GAS_BIGASS
static const int CONTAMINATED_AREA_GAS_AROUND
static const int CONTAMINATED_AREA_GAS_TINY
Entity which has the particle instance as an ObjectComponent.
static vector RotateAroundZero(vector pos, vector axis, float cosAngle, float sinAngle)
Rotate a vector around 0,0,0.
proto native CGame GetGame()
void Error(string err)
Messagebox with error message.
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
static proto float Acos(float c)
Returns angle in radians from cosinus.
static proto float Cos(float angle)
Returns cosinus of angle in radians.
static proto float Sin(float angle)
Returns sinus of angle in radians.
static proto int SqrInt(int i)
Returns squared value.
proto native ToType()
Returns internal type representation. Can be used in runtime, or cached in variables and used for fas...