DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ OnSteppedOn()

override void OnSteppedOn ( EntityAI victim)
protected

См. определение в файле Trap_TripWire.c строка 72

73 {
74 if (!victim)
75 {
76 return;
77 }
78
79 if (!victim.GetAllowDamage())
80 {
81 return;
82 }
83
84 // We must deal some damage, here 5 shock as melee damage in order to trigger hit animation
85 if (GetGame().IsServer())
86 {
87 victim.ProcessDirectDamage(DamageType.CLOSE_COMBAT, this, "", "TripWireHit", "0 0 0", 1);
89 SetInactive(false);
90 }
91
92 // We play the trap trigger sound
93 #ifndef SERVER
94 EffectSound sound = SEffectManager.PlaySound("TripwireTrap_Trigger_SoundSet", GetPosition());
95 sound.SetAutodestroy(true);
96 #endif
97 }
DamageType
exposed from C++ (do not change)
Определения DamageSystem.c:11
static const int TRIGGERED
Определения Trap_TripWire.c:14
override void SetInactive(bool stop_timer=true)
Определения Trap_TripWire.c:150
void SetState(int state_ID)
Определения Trap_TripWire.c:171
override void SetAutodestroy(bool auto_destroy)
Sets whether Effect automatically cleans up when it stops.
Определения EffectSound.c:603
Wrapper class for managing sound through SEffectManager.
Определения EffectSound.c:5
static EffectSound PlaySound(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound.
Определения EffectManager.c:169
Manager class for managing Effect (EffectParticle, EffectSound)
Определения EffectManager.c:6
proto native CGame GetGame()
class JsonUndergroundAreaTriggerData GetPosition
Определения UndergroundAreaLoader.c:9

Перекрестные ссылки GetGame(), GetPosition, SEffectManager::PlaySound(), EffectSound::SetAutodestroy(), SetInactive(), SetState() и TRIGGERED.