DayZ 1.24
Loading...
Searching...
No Matches
TremorMdfr Class Reference
Inheritance diagram for TremorMdfr:
[legend]
Collaboration diagram for TremorMdfr:
[legend]

Private Member Functions

override void Init ()
 
override bool ActivateCondition (PlayerBase player)
 
override bool DeactivateCondition (PlayerBase player)
 
override void OnTick (PlayerBase player, float deltaT)
 

Private Attributes

const float TREMOR_DECREMENT_PER_SEC = 0.008
 

Detailed Description

Definition at line 1 of file Tremor.c.

Member Function Documentation

◆ ActivateCondition()

override bool TremorMdfr::ActivateCondition ( PlayerBase player)
inlineprivate

Definition at line 13 of file Tremor.c.

14 {
15 if (player.GetStatTremor().Get() > player.GetStatTremor().GetMin())
16 return true;
17 else
18 return false;
19 }

◆ DeactivateCondition()

override bool TremorMdfr::DeactivateCondition ( PlayerBase player)
inlineprivate

Definition at line 21 of file Tremor.c.

22 {
23 if (player.GetStatTremor().Get() == player.GetStatTremor().GetMin())
24 return true;
25 else
26 return false;
27 }

◆ Init()

override void TremorMdfr::Init ( )
inlineprivate

Definition at line 5 of file Tremor.c.

6 {
8 m_ID = eModifiers.MDF_TREMOR;
11 }
int m_ID
ID of effect, given by SEffectManager when registered (automatically done when playing through it)
Definition Effect.c:49
bool m_TrackActivatedTime
float m_TickIntervalActive
float m_TickIntervalInactive
const int DEFAULT_TICK_TIME_INACTIVE
const int DEFAULT_TICK_TIME_ACTIVE
eModifiers
Definition eModifiers.c:2

References DEFAULT_TICK_TIME_ACTIVE, DEFAULT_TICK_TIME_INACTIVE, m_ID, m_TickIntervalActive, m_TickIntervalInactive, and m_TrackActivatedTime.

◆ OnTick()

override void TremorMdfr::OnTick ( PlayerBase player,
float deltaT )
inlineprivate

Definition at line 29 of file Tremor.c.

30 {
31 player.GetStatTremor().Add((TREMOR_DECREMENT_PER_SEC * deltaT));
32
33 //Mirek: SetShakeBodyFactor is removed now, because it worked only on legacy animation system
34 //player.SetShakeBodyFactor(player.GetStatTremor().Get());
35 //_person SetBodyShaking tremor; ASK GAMEPLAY PROGRAMMERS TO EXPOSE THIS ENGINE FUNCTION IN ENSCRIPT
36 //PrintString( "Tremor:" + ToString(tremor) );
37 }
const float TREMOR_DECREMENT_PER_SEC
Definition Tremor.c:3

References TREMOR_DECREMENT_PER_SEC.

Member Data Documentation

◆ TREMOR_DECREMENT_PER_SEC

const float TremorMdfr::TREMOR_DECREMENT_PER_SEC = 0.008
private

Definition at line 3 of file Tremor.c.

Referenced by OnTick().


The documentation for this class was generated from the following file: