10 bool m_DealDamageFlag;
13 int m_EffectsPriority;
17 RegisterNetSyncVariableInt(
"m_AroundPartId");
18 RegisterNetSyncVariableInt(
"m_TinyPartId");
19 RegisterNetSyncVariableInt(
"m_PPERequester");
20 RegisterNetSyncVariableInt(
"m_EffectsPriority");
30 void SetLocalEffects(
int aroundPartId,
int tinyPartId,
int ppeRequesterIdx )
32 m_AroundPartId = aroundPartId;
33 m_TinyPartId = tinyPartId;
47 m_EffectsPriority = priority;
50 int GetEffectsPriority()
52 return m_EffectsPriority;
55 string GetAmbientSoundsetName()
60 void SetupClientEffects(
bool enable, notnull
PlayerBase player)
62 if ( !
m_Manager.IsPlayerInTriggerType( player,
this ) )
66 player.SetContaminatedEffectEx(
true, m_PPERequester, m_AroundPartId, m_TinyPartId, GetAmbientSoundsetName() );
70 player.SetContaminatedEffectEx(
false, m_PPERequester );
80 override void EOnFrame(
IEntity other,
float timeSlice)
82 m_DeltaTime = timeSlice;
85 override bool CanAddObjectAsInsider(
Object object)
91 return !creature.ResistContaminatedEffect();
96 return player !=
null;
100 return (player && player.IsControlledPlayer());
104 override protected void OnStayClientEvent(
TriggerInsider insider,
float deltaTime)
106 super.OnStayClientEvent(insider, deltaTime);
109 player.RequestTriggerEffect(
this, m_PPERequester, m_AroundPartId, m_TinyPartId, GetAmbientSoundsetName() );
114 super.OnEnterServerEvent( insider );
124 m_Manager.OnPlayerEnter( playerInsider,
this );
133 super.OnEnterClientEvent( insider );
140 if (playerInsider && playerInsider.IsControlledPlayer() )
144 m_Manager.OnPlayerEnter( playerInsider,
this );
152 super.OnLeaveServerEvent( insider );
159 m_Manager.OnPlayerExit( playerInsider,
this );
167 super.OnLeaveClientEvent( insider );
176 if ( playerInsider && playerInsider.IsControlledPlayer() )
179 m_Manager.OnPlayerExit( playerInsider,
this );
188 return !insider.GetObject().IsAlive();
193 static void TriggerEffect(
EntityAI insider,
typename triggerType ) {}