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

Private Member Functions

void DamageDealtEffect ()
 
void ~DamageDealtEffect ()
 
void Update (float deltatime)
 

Private Attributes

const float ALPHA_MIN = 0
 
const float ALPHA_MAX = 1
 
float m_HitDuration
 
float m_BreakPoint
 
float m_TimeActive
 
PPERequester_HealthHitReaction m_Requester
 

Detailed Description

Definition at line 1 of file BulletHitReaction.c.

Constructor & Destructor Documentation

◆ DamageDealtEffect()

void DamageDealtEffect::DamageDealtEffect ( )
inlineprivate

Definition at line 10 of file BulletHitReaction.c.

11 {
12 m_HitDuration = 0.10;
13 m_BreakPoint = 0.05;
15 //Print("=====================================================");
16 //Print("=====================================================");
17 }
Super root of all classes in Enforce script.
Definition EnScript.c:11
PPERequester_HealthHitReaction m_Requester
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.

References Class::CastTo(), m_BreakPoint, m_HitDuration, and m_Requester.

◆ ~DamageDealtEffect()

void DamageDealtEffect::~DamageDealtEffect ( )
inlineprivate

Definition at line 19 of file BulletHitReaction.c.

20 {
22 }

Member Function Documentation

◆ Update()

void DamageDealtEffect::Update ( float deltatime)
inlineprivate

Definition at line 24 of file BulletHitReaction.c.

25 {
26 float value;
27
30 else
31 {
33 value = 1 - tmp_value;
34 }
36 value = Math.Clamp(value, 0, 1);
38 //Print(val);
39 m_Requester.SetHitIntensity(val);
40
42 delete this;
43 }
Definition EnMath.c:7
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...

References ALPHA_MAX, ALPHA_MIN, Math::Clamp(), Math::InverseLerp(), Math::Lerp(), m_BreakPoint, m_HitDuration, m_Requester, and m_TimeActive.

Member Data Documentation

◆ ALPHA_MAX

const float DamageDealtEffect::ALPHA_MAX = 1
private

Definition at line 4 of file BulletHitReaction.c.

Referenced by Update().

◆ ALPHA_MIN

const float DamageDealtEffect::ALPHA_MIN = 0
private

Definition at line 3 of file BulletHitReaction.c.

Referenced by Update().

◆ m_BreakPoint

float DamageDealtEffect::m_BreakPoint
private

Definition at line 6 of file BulletHitReaction.c.

Referenced by DamageDealtEffect(), and Update().

◆ m_HitDuration

float DamageDealtEffect::m_HitDuration
private

Definition at line 5 of file BulletHitReaction.c.

Referenced by DamageDealtEffect(), and Update().

◆ m_Requester

PPERequester_HealthHitReaction DamageDealtEffect::m_Requester
private

Definition at line 8 of file BulletHitReaction.c.

Referenced by DamageDealtEffect(), and Update().

◆ m_TimeActive

float DamageDealtEffect::m_TimeActive
private

Definition at line 7 of file BulletHitReaction.c.

Referenced by Update().


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