DayZ 1.24
Loading...
Searching...
No Matches
HealthNotfr.c
Go to the documentation of this file.
2{
3 /*
4 private const float HEALTHY_BLOOD_TRESHOLD = 5000;
5 private const float HEALTHY_TRESHOLD = 5000;
6 private const float HEALING_ENERGY_TRESHOLD = 4000;
7 private const float HEALING_WATER_TRESHOLD = 2500;
8 private const float HEALING_BLOOD_TRESHOLD = 5000;
9 */
10 private const float DEC_TRESHOLD_LOW = 0;
11 private const float DEC_TRESHOLD_MED = -0.7;
12 private const float DEC_TRESHOLD_HIGH = -1.3;
13 private const float INC_TRESHOLD_LOW = 0;
14 private const float INC_TRESHOLD_MED = 0.7;
15 private const float INC_TRESHOLD_HIGH = 1.3;
16
17
23
24 override int GetNotifierType()
25 {
26 return eNotifiers.NTF_HEALTHY;
27 }
28
29 override void DisplayBadge()
30 {
31 }
32
33 override void DisplayTendency(float delta)
34 {
36 //PrintString("tendency:" + tendency);
37 //GetVirtualHud().SetStatus(eDisplayElements.DELM_TDCY_HEALTH,tendency);
38
39 //DSLevels level = DetermineLevel( GetObservedValue(), PlayerConstants.THRESHOLD_HEALTH_WARNING, PlayerConstants.THRESHOLD_HEALTH_CRITICAL, PlayerConstants.THRESHOLD_HEALTH_BLINKING, PlayerConstants.THRESHOLD_HEALTH_EXTRA);
40
41 EStatLevels health_level = m_Player.GetStatLevelHealth();
43
44 if (dis_elm)
45 {
46 dis_elm.SetSeriousnessLevel(health_level);
47 dis_elm.SetTendency(tendency);
48 }
49 }
50
51 override void HideBadge()
52 {
53
55 }
56
57 override protected float GetObservedValue()
58 {
59 float health = m_Player.GetHealth("", "Health");
60 //PrintString("health:" + health);
61 return health;
62 }
63
64
65};
DisplayElementBase GetElement(eDisplayElements element_id)
EStatLevels
Definition EStatLevels.c:2
void NotifiersManager(PlayerBase player)
eNotifiers
const float DEC_TRESHOLD_HIGH
Definition HealthNotfr.c:12
const float INC_TRESHOLD_LOW
Definition HealthNotfr.c:13
const float DEC_TRESHOLD_MED
Definition HealthNotfr.c:11
const float INC_TRESHOLD_HIGH
Definition HealthNotfr.c:15
override void DisplayTendency(float delta)
Definition HealthNotfr.c:33
const float INC_TRESHOLD_MED
Definition HealthNotfr.c:14
override void HideBadge()
Definition HealthNotfr.c:51
const float DEC_TRESHOLD_LOW
Definition HealthNotfr.c:10
void HealthNotfr(NotifiersManager manager)
Definition HealthNotfr.c:18
float GetObservedValue()
Definition HealthNotfr.c:57
override int GetNotifierType()
Definition HealthNotfr.c:24
override void DisplayBadge()
Definition HealthNotfr.c:29
PlayerBase m_Player
Definition NotifierBase.c:6
VirtualHud GetVirtualHud()
int CalculateTendency(float delta, float inctresholdlow, float inctresholdmed, float inctresholdhigh, float dectresholdlow, float dectresholdmed, float dectresholdhigh)
int m_TendencyBufferSize
Definition NotifierBase.c:9