DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Класс HeatComfortAnimHandler

Защищенные члены

void HeatComfortAnimHandler (PlayerBase player)
 
void Update (float delta_time, HumanMovementState hms)
 
float GetEventTime (float hc_value, float threshold_low, float threshold_high, float low_min, float high_min, float low_max, float high_max)
 
void Process (float delta_time)
 

Защищенные данные

ref HumanMovementState m_MovementState = new HumanMovementState()
 
const float TIME_INTERVAL_HC_MINUS_LOW_MIN = 5
 
const float TIME_INTERVAL_HC_MINUS_LOW_MAX = 12
 
const float TIME_INTERVAL_HC_MINUS_HIGH_MIN = 15
 
const float TIME_INTERVAL_HC_MINUS_HIGH_MAX = 25
 
const float TIME_INTERVAL_HC_PLUS_LOW_MIN = 5
 
const float TIME_INTERVAL_HC_PLUS_LOW_MAX = 12
 
const float TIME_INTERVAL_HC_PLUS_HIGH_MIN = 15
 
const float TIME_INTERVAL_HC_PLUS_HIGH_MAX = 25
 

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

const float TICK_INTERVAL = 2
 
float m_TimeSinceLastTick
 
float m_ProcessTimeAccuFreeze
 
float m_ProcessTimeAccuHot
 
PlayerBase m_Player
 
float m_EventTimeFreeze = -1
 
float m_EventTimeHot = -1
 

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

Конструктор(ы)

◆ HeatComfortAnimHandler()

void HeatComfortAnimHandler ( PlayerBase player)
inlineprotected
20 {
22 }
PlayerBase m_Player
Definition HeatComfortAnimHandler.c:8
Definition EntityAI.c:95

Перекрестные ссылки m_Player.

Методы

◆ GetEventTime()

float GetEventTime ( float hc_value,
float threshold_low,
float threshold_high,
float low_min,
float high_min,
float low_max,
float high_max )
inlineprotected
36 {
40
42 }
Definition EnMath.c:7
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...
static float RandomFloatInclusive(float min, float max)
Returns a random float number between and min [inclusive] and max [inclusive].
Definition EnMath.c:106
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.

Перекрестные ссылки Math::InverseLerp(), Math::Lerp() и Math::RandomFloatInclusive().

Используется в Process().

◆ Process()

void Process ( float delta_time)
inlineprotected
46 {
47 if( GetGame().IsServer() )
48 {
49
50 float hc = m_Player.GetStatHeatComfort().Get();
51 float inv_value;
52 float value_min;
53 float value_max;
54 float offset_time;
55
57 {
59
60 if(m_EventTimeFreeze < 0)//if not set
61 {
63 }
64
66 {
69 m_Player.GetSymptomManager().QueueUpPrimarySymptom(SymptomIDs.SYMPTOM_FREEZE);
70 /*
71 Print("-----======== freezing ========-------");
72 Print(inv_value);
73 Print(value_min);
74 Print(value_max);
75 Print(offset_time);
76 Print("-----======== freezing ========-------");
77 */
78 }
79 }
81 {
83
84 if(m_EventTimeHot < 0)//if not set
85 {
87 }
88
90 {
92 m_EventTimeHot = -1;
93 m_Player.GetSymptomManager().QueueUpPrimarySymptom(SymptomIDs.SYMPTOM_HOT);
94
95 //Print("-----======== freezing ========-------");
96 //Print(inv_value);
97 //Print(value_min);
98 //Print(value_max);
99 //Print(offset_time);
100 //Print("-----======== freezing ========-------");
101
102 }
103 }
104 }
105 }
const float TIME_INTERVAL_HC_PLUS_LOW_MIN
Definition HeatComfortAnimHandler.c:16
const float TIME_INTERVAL_HC_MINUS_LOW_MIN
Definition HeatComfortAnimHandler.c:13
float m_EventTimeFreeze
Definition HeatComfortAnimHandler.c:9
const float TIME_INTERVAL_HC_PLUS_HIGH_MAX
Definition HeatComfortAnimHandler.c:17
const float TIME_INTERVAL_HC_MINUS_LOW_MAX
Definition HeatComfortAnimHandler.c:13
float m_ProcessTimeAccuFreeze
Definition HeatComfortAnimHandler.c:5
float m_ProcessTimeAccuHot
Definition HeatComfortAnimHandler.c:6
float GetEventTime(float hc_value, float threshold_low, float threshold_high, float low_min, float high_min, float low_max, float high_max)
Definition HeatComfortAnimHandler.c:35
const float TIME_INTERVAL_HC_MINUS_HIGH_MIN
Definition HeatComfortAnimHandler.c:14
const float TIME_INTERVAL_HC_PLUS_LOW_MAX
Definition HeatComfortAnimHandler.c:16
const float TIME_INTERVAL_HC_MINUS_HIGH_MAX
Definition HeatComfortAnimHandler.c:14
float m_EventTimeHot
Definition HeatComfortAnimHandler.c:10
Definition PlayerConstants.c:2
static const float THRESHOLD_HEAT_COMFORT_MINUS_WARNING
Definition PlayerConstants.c:84
static const float THRESHOLD_HEAT_COMFORT_PLUS_WARNING
Definition PlayerConstants.c:80
static const float THRESHOLD_HEAT_COMFORT_PLUS_EMPTY
Definition PlayerConstants.c:82
static const float THRESHOLD_HEAT_COMFORT_MINUS_EMPTY
Definition PlayerConstants.c:86
proto native CGame GetGame()

Перекрестные ссылки GetEventTime(), GetGame(), m_EventTimeFreeze, m_EventTimeHot, m_Player, m_ProcessTimeAccuFreeze, m_ProcessTimeAccuHot, PlayerConstants::THRESHOLD_HEAT_COMFORT_MINUS_EMPTY, PlayerConstants::THRESHOLD_HEAT_COMFORT_MINUS_WARNING, PlayerConstants::THRESHOLD_HEAT_COMFORT_PLUS_EMPTY, PlayerConstants::THRESHOLD_HEAT_COMFORT_PLUS_WARNING, TIME_INTERVAL_HC_MINUS_HIGH_MAX, TIME_INTERVAL_HC_MINUS_HIGH_MIN, TIME_INTERVAL_HC_MINUS_LOW_MAX, TIME_INTERVAL_HC_MINUS_LOW_MIN, TIME_INTERVAL_HC_PLUS_HIGH_MAX, TIME_INTERVAL_HC_PLUS_LOW_MAX и TIME_INTERVAL_HC_PLUS_LOW_MIN.

◆ Update()

void Update ( float delta_time,
HumanMovementState hms )
inlineprotected
25 {
27
29 {
32 }
33 }
void Process()
Definition EffectManager.c:743
const float TICK_INTERVAL
Definition HeatComfortAnimHandler.c:3
float m_TimeSinceLastTick
Definition HeatComfortAnimHandler.c:4

Перекрестные ссылки m_TimeSinceLastTick, Process() и TICK_INTERVAL.

Поля

◆ m_EventTimeFreeze

float m_EventTimeFreeze = -1
private

Используется в Process().

◆ m_EventTimeHot

float m_EventTimeHot = -1
private

Используется в Process().

◆ m_MovementState

ref HumanMovementState m_MovementState = new HumanMovementState()
protected

◆ m_Player

PlayerBase m_Player
private

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

◆ m_ProcessTimeAccuFreeze

float m_ProcessTimeAccuFreeze
private

Используется в Process().

◆ m_ProcessTimeAccuHot

float m_ProcessTimeAccuHot
private

Используется в Process().

◆ m_TimeSinceLastTick

float m_TimeSinceLastTick
private

Используется в Update().

◆ TICK_INTERVAL

const float TICK_INTERVAL = 2
private

Используется в Update().

◆ TIME_INTERVAL_HC_MINUS_HIGH_MAX

const float TIME_INTERVAL_HC_MINUS_HIGH_MAX = 25
protected

Используется в Process().

◆ TIME_INTERVAL_HC_MINUS_HIGH_MIN

const float TIME_INTERVAL_HC_MINUS_HIGH_MIN = 15
protected

Используется в Process().

◆ TIME_INTERVAL_HC_MINUS_LOW_MAX

const float TIME_INTERVAL_HC_MINUS_LOW_MAX = 12
protected

Используется в Process().

◆ TIME_INTERVAL_HC_MINUS_LOW_MIN

const float TIME_INTERVAL_HC_MINUS_LOW_MIN = 5
protected

Используется в Process().

◆ TIME_INTERVAL_HC_PLUS_HIGH_MAX

const float TIME_INTERVAL_HC_PLUS_HIGH_MAX = 25
protected

Используется в Process().

◆ TIME_INTERVAL_HC_PLUS_HIGH_MIN

const float TIME_INTERVAL_HC_PLUS_HIGH_MIN = 15
protected

◆ TIME_INTERVAL_HC_PLUS_LOW_MAX

const float TIME_INTERVAL_HC_PLUS_LOW_MAX = 12
protected

Используется в Process().

◆ TIME_INTERVAL_HC_PLUS_LOW_MIN

const float TIME_INTERVAL_HC_PLUS_LOW_MIN = 5
protected

Используется в Process().


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