DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс BoneRegenMdfr
+ Граф наследования:BoneRegenMdfr:

Закрытые члены

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

Закрытые данные

const float MINIMAL_WATER_TO_REGENRATE = 2500
 
const float MINIMAL_ENERGY_TO_REGENRATE = 4000
 
const float MINIMAL_BLOOD_TO_REGENRATE = 5000
 
const float MINIMAL_BLOOD_REQUIRED_TO_REGENERATE_HEALTH = 5000
 
const float BONE_HEALTH_INCREMENT_PER_SEC = 0.25
 

Подробное описание

Методы

◆ ActivateCondition()

override bool ActivateCondition ( PlayerBase player)
inlineprivate
18 {
19 if ( player.GetHealth("GlobalHealth", "Blood") >= MINIMAL_BLOOD_TO_REGENRATE && player.GetStatWater().Get() >= MINIMAL_WATER_TO_REGENRATE && player.GetStatEnergy().Get() >= MINIMAL_ENERGY_TO_REGENRATE )
20 {
21 return true;
22 }
23 else
24 {
25 return false;
26 }
27 }
const float MINIMAL_ENERGY_TO_REGENRATE
Definition BoneRegen.c:4
const float MINIMAL_WATER_TO_REGENRATE
Definition BoneRegen.c:3
const float MINIMAL_BLOOD_TO_REGENRATE
Definition BoneRegen.c:5
Definition EntityAI.c:95

Перекрестные ссылки MINIMAL_BLOOD_TO_REGENRATE, MINIMAL_ENERGY_TO_REGENRATE и MINIMAL_WATER_TO_REGENRATE.

◆ DeactivateCondition()

override bool DeactivateCondition ( PlayerBase player)
inlineprivate
34 {
35 if ( player.GetHealth("GlobalHealth", "Blood") < MINIMAL_BLOOD_TO_REGENRATE && player.GetStatWater().Get() < MINIMAL_WATER_TO_REGENRATE && player.GetStatEnergy().Get() < MINIMAL_ENERGY_TO_REGENRATE )
36 {
37 return true;
38 }
39 else
40 {
41 return false;
42 }
43 }

Перекрестные ссылки MINIMAL_BLOOD_TO_REGENRATE, MINIMAL_ENERGY_TO_REGENRATE и MINIMAL_WATER_TO_REGENRATE.

◆ Init()

override void Init ( )
inlineprivate
10 {
12 m_ID = eModifiers.MDF_BONE_REGEN;
15 }
int m_ID
ID of effect, given by SEffectManager when registered (automatically done when playing through it)
Definition Effect.c:49
bool m_TrackActivatedTime
overall time this modifier was active
Definition ModifierBase.c:14
float m_TickIntervalActive
Definition ModifierBase.c:18
float m_TickIntervalInactive
Definition ModifierBase.c:17
const int DEFAULT_TICK_TIME_INACTIVE
Definition ModifiersManager.c:29
enum eModifierSyncIDs DEFAULT_TICK_TIME_ACTIVE
eModifiers
Definition eModifiers.c:2

Перекрестные ссылки DEFAULT_TICK_TIME_ACTIVE, DEFAULT_TICK_TIME_INACTIVE, m_ID, m_TickIntervalActive, m_TickIntervalInactive и m_TrackActivatedTime.

◆ OnActivate()

override void OnActivate ( PlayerBase player)
inlineprivate
30 {
31 }

◆ OnTick()

override void OnTick ( PlayerBase player,
float deltaT )
inlineprivate
46 {
47 /*
48 player.AddHealth("RightArm","Health",BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
49 player.AddHealth("RightHand","Health",BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
50 player.AddHealth("LeftArm","Health",BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
51 player.AddHealth("LeftHand","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
52
53 player.AddHealth("RightLeg","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
54 player.AddHealth("RightFoot","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
55 player.AddHealth("LeftLeg","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
56 player.AddHealth("LeftFoot","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
57
58 player.AddHealth("Torso","Health",+BONE_HEALTH_INCREMENT_PER_SEC * deltaT);
59 */
60 }

Поля

◆ BONE_HEALTH_INCREMENT_PER_SEC

const float BONE_HEALTH_INCREMENT_PER_SEC = 0.25
private

◆ MINIMAL_BLOOD_REQUIRED_TO_REGENERATE_HEALTH

const float MINIMAL_BLOOD_REQUIRED_TO_REGENERATE_HEALTH = 5000
private

◆ MINIMAL_BLOOD_TO_REGENRATE

const float MINIMAL_BLOOD_TO_REGENRATE = 5000
private

Используется в ActivateCondition() и DeactivateCondition().

◆ MINIMAL_ENERGY_TO_REGENRATE

const float MINIMAL_ENERGY_TO_REGENRATE = 4000
private

Используется в ActivateCondition() и DeactivateCondition().

◆ MINIMAL_WATER_TO_REGENRATE

const float MINIMAL_WATER_TO_REGENRATE = 2500
private

Используется в ActivateCondition() и DeactivateCondition().


Объявления и описания членов класса находятся в файле: