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

Private Member Functions

void InjuredLegNotfr (NotifiersManager manager)
 
override int GetNotifierType ()
 
override void DisplayBadge ()
 
override void HideBadge ()
 
- Private Member Functions inherited from NotifierBase
int CalculateTendency (float delta, float inctresholdlow, float inctresholdmed, float inctresholdhigh, float dectresholdlow, float dectresholdmed, float dectresholdhigh)
 
eBadgeLevel DetermineBadgeLevel (float value, float lvl_1, float lvl_2, float lvl_3)
 
void DisplayBadge ()
 
void HideBadge ()
 
float GetObservedValue ()
 

Detailed Description

Definition at line 1 of file InjuredLegNotfr.c.

Constructor & Destructor Documentation

◆ InjuredLegNotfr()

void InjuredLegNotfr::InjuredLegNotfr ( NotifiersManager manager)
inlineprivate

Definition at line 3 of file InjuredLegNotfr.c.

4 {
5 m_Active = true;
6 }

References NotifierBase::m_Active.

Member Function Documentation

◆ DisplayBadge()

override void InjuredLegNotfr::DisplayBadge ( )
inlineprivate

Definition at line 14 of file InjuredLegNotfr.c.

15 {
17
18
19 if (dis_elm)
20 {
21 float legHealthInverted = 1 - Math.Min(m_Player.GetHealth01("LeftLeg", ""), m_Player.GetHealth01("RightLeg", ""));
22 int level = eBadgeLevel.NONE;
23 if (m_Player.GetBrokenLegs() == eBrokenLegs.NO_BROKEN_LEGS)
24 level = DetermineBadgeLevel(legHealthInverted, 0.05, 0.35, 0.65);
25 dis_elm.SetLevel(level);
26 }
27 }
eBadgeLevel
Definition _constants.c:2
DisplayElementBase GetElement(eDisplayElements element_id)
eBrokenLegs
Definition EBrokenLegs.c:2
Definition EnMath.c:7
PlayerBase m_Player
Definition NotifierBase.c:6
eBadgeLevel DetermineBadgeLevel(float value, float lvl_1, float lvl_2, float lvl_3)
VirtualHud GetVirtualHud()
static proto float Min(float x, float y)
Returns smaller of two given values.

References NotifierBase::DetermineBadgeLevel(), GetElement(), NotifierBase::GetVirtualHud(), NotifierBase::m_Player, and Math::Min().

◆ GetNotifierType()

override int InjuredLegNotfr::GetNotifierType ( )
inlineprivate

Definition at line 8 of file InjuredLegNotfr.c.

9 {
10 return eNotifiers.NTF_LEGS;
11 }
eNotifiers

◆ HideBadge()

override void InjuredLegNotfr::HideBadge ( )
inlineprivate

Definition at line 29 of file InjuredLegNotfr.c.

30 {
32 if (dis_elm)
33 dis_elm.SetLevel(eBadgeLevel.NONE);
34 }

References GetElement(), and NotifierBase::GetVirtualHud().


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