Dayz Build 1.29.163047, Scripts Rev. 123548
Dayz Code Explorer by Zeroy
Loading...
Searching...
No Matches
TrapBase Class Reference

Protected Member Functions

void CauseVictimToStartLimping (Object obj, string damagedZone)
override string GetLoopDeploySoundset ()
override bool IsDeployable ()
override void OnActivate ()
override void OnDisarm ()
override void OnPlacementComplete (Man player, vector position="0 0 0", vector orientation="0 0 0")
void OnServerSteppedOn (Object obj, string damageZone)
void PlaySoundBiteEmpty ()
void PlaySoundBiteLeg ()
void PlaySoundOpen ()
override void SetActions ()

Private Member Functions

void BearTrap ()
override bool CanBeDisarmed ()
override void CreateTrigger ()
override void EEHealthLevelChanged (int oldLevel, int newLevel, string zone)
override void OnSteppedOn (EntityAI victim)
override void OnSteppedOut (EntityAI victim)
override void OnUpdate (EntityAI victim)

Static Private Attributes

static const vector m_RaycastSources [RAYCAST_SOURCES_COUNT]
static const int RAYCAST_SOURCES_COUNT = 5

Detailed Description

Definition at line 1 of file trap_bear.c.

Member Function Documentation

◆ BearTrap()

void BearTrap ( )
inlineprivate

◆ CanBeDisarmed()

override bool CanBeDisarmed ( )
inlineprivate

Definition at line 25 of file trap_bear.c.

◆ CauseVictimToStartLimping()

void CauseVictimToStartLimping ( Object obj,
string damagedZone )
inlineprotected

Definition at line 177 of file trap_bear.c.

References Class::CastTo().

Referenced by OnServerSteppedOn().

◆ CreateTrigger()

override void CreateTrigger ( )
inlineprivate

Definition at line 43 of file trap_bear.c.

References GetOrientation(), and m_TrapTrigger.

Referenced by SetActive().

◆ EEHealthLevelChanged()

override void EEHealthLevelChanged ( int oldLevel,
int newLevel,
string zone )
inlineprivate

Definition at line 30 of file trap_bear.c.

References g_Game, SetInactive(), and GameConstants::STATE_RUINED.

◆ GetLoopDeploySoundset()

override string GetLoopDeploySoundset ( )
inlineprotected

Definition at line 244 of file trap_bear.c.

◆ IsDeployable()

override bool IsDeployable ( )
inlineprotected

Definition at line 239 of file trap_bear.c.

◆ OnActivate()

override void OnActivate ( )
inlineprotected

Definition at line 210 of file trap_bear.c.

References PlaySoundOpen().

Referenced by SetActive().

◆ OnDisarm()

override void OnDisarm ( )
inlineprotected

Definition at line 217 of file trap_bear.c.

References PlaySoundBiteEmpty().

Referenced by Disarm(), and OnRPC().

◆ OnPlacementComplete()

override void OnPlacementComplete ( Man player,
vector position = "0 0 0",
vector orientation = "0 0 0" )
inlineprotected

Definition at line 228 of file trap_bear.c.

References g_Game, and StartActivate().

Referenced by OnFinishProgressServer().

◆ OnServerSteppedOn()

void OnServerSteppedOn ( Object obj,
string damageZone )
inlineprotected

Generic limp handling

Definition at line 136 of file trap_bear.c.

References Class::CastTo(), CauseVictimToStartLimping(), m_UpdateTimer, Math::RandomIntInclusive(), SetInactive(), and Synch().

Referenced by OnSteppedOn(), OnUpdate(), and OnUpdate().

◆ OnSteppedOn()

override void OnSteppedOn ( EntityAI victim)
inlineprivate

CarScript specific reaction on BearTrap

this is also called on client (OnRPC->SnapOn->OnSteppedOn chain)

Definition at line 67 of file trap_bear.c.

References RaycastRVParams::flags, g_Game, m_RaycastSources, m_UpdateTimer, OnServerSteppedOn(), PlaySoundBiteLeg(), RaycastRVParams::radius, DayZPhysics::RaycastRVProxy(), RaycastRVParams::type, and UPDATE_TIMER_INTERVAL.

Referenced by SnapOnObject().

◆ OnSteppedOut()

override void OnSteppedOut ( EntityAI victim)
inlineprivate

Definition at line 125 of file trap_bear.c.

References m_UpdateTimer.

Referenced by RemoveFromObject().

◆ OnUpdate()

override void OnUpdate ( EntityAI victim)
inlineprivate

Definition at line 55 of file trap_bear.c.

References GetClosestCarWheel(), and OnServerSteppedOn().

◆ PlaySoundBiteEmpty()

void PlaySoundBiteEmpty ( )
inlineprotected

Definition at line 198 of file trap_bear.c.

References GetPosition(), SEffectManager::PlaySound(), and EffectSound::SetAutodestroy().

Referenced by OnDisarm().

◆ PlaySoundBiteLeg()

void PlaySoundBiteLeg ( )
inlineprotected

Definition at line 192 of file trap_bear.c.

References GetPosition(), SEffectManager::PlaySound(), and EffectSound::SetAutodestroy().

Referenced by OnSteppedOn().

◆ PlaySoundOpen()

void PlaySoundOpen ( )
inlineprotected

Definition at line 204 of file trap_bear.c.

References GetPosition(), SEffectManager::PlaySound(), and EffectSound::SetAutodestroy().

Referenced by OnActivate().

◆ SetActions()

override void SetActions ( )
inlineprotected

Definition at line 249 of file trap_bear.c.

References ActionDeployObject(), and AddAction().

Field Documentation

◆ m_RaycastSources

const vector m_RaycastSources[RAYCAST_SOURCES_COUNT]
staticprivate
Initial value:
= {
"0.0 0.1 0.0",
"0.2 0.1 0.2",
"-.2 0.1 0.2",
"0.2 0.1 -0.2",
"-0.2 0.1 -0.2"
}

Definition at line 6 of file trap_bear.c.

Referenced by OnSteppedOn().

◆ RAYCAST_SOURCES_COUNT

const int RAYCAST_SOURCES_COUNT = 5
staticprivate

Definition at line 3 of file trap_bear.c.


The documentation for this class was generated from the following file:
  • F:/Games/Dayz/scripts/4_world/entities/itembase/trapbase/trap_bear.c