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

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

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

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

override void Init ()
 
override string GetDebugText ()
 

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

const int AGENT_THRESHOLD_ACTIVATE = 1150
 
const int AGENT_THRESHOLD_DEACTIVATE = 1100
 
const float STAMINA_DEPLETION_MULTIPLIER = 1.3
 
const float STAMINA_RECOVERY_MULTIPLIER = 0.5
 
const float HEALTH_LOSS_PNEUMONIA = 0.1
 
const int TEMPORARY_RESISTANCE_TIME = 600
 

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

Методы

◆ ActivateCondition()

bool ActivateCondition ( PlayerBase player)
inlineprotected
28 {
29 if (player.GetSingleAgentCount(eAgents.INFLUENZA) >= AGENT_THRESHOLD_ACTIVATE)
30 return true;
31
32 return false;
33 }
eAgents
Definition EAgents.c:3
Definition EntityAI.c:95
const int AGENT_THRESHOLD_ACTIVATE
Definition Pneumonia.c:3

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

◆ DeactivateCondition()

bool DeactivateCondition ( PlayerBase player)
inlineprotected
54 {
55 return (player.GetSingleAgentCount(eAgents.INFLUENZA) <= AGENT_THRESHOLD_DEACTIVATE);
56 }
const int AGENT_THRESHOLD_DEACTIVATE
Definition Pneumonia.c:4

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

◆ GetDebugText()

override string GetDebugText ( )
inlineprivate
23 {
24 return ("Activate threshold: "+AGENT_THRESHOLD_ACTIVATE + "| " +"Deativate threshold: "+AGENT_THRESHOLD_DEACTIVATE);
25 }

Перекрестные ссылки AGENT_THRESHOLD_ACTIVATE и AGENT_THRESHOLD_DEACTIVATE.

◆ Init()

override void Init ( )
inlineprivate
14 {
17 m_ID = eModifiers.MDF_PNEUMONIA;
20 }
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
bool m_AnalyticsStatsEnabled
Definition ModifierBase.c:31
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_AnalyticsStatsEnabled, m_ID, m_TickIntervalActive, m_TickIntervalInactive и m_TrackActivatedTime.

◆ OnActivate()

void OnActivate ( PlayerBase player)
inlineprotected
36 {
37 player.IncreaseDiseaseCount();
38
39 player.GetStaminaHandler().ActivateRecoveryModifier(EStaminaMultiplierTypes.DISEASE_PNEUMONIA);
40 player.GetStaminaHandler().ActivateDepletionModifier(EStaminaMultiplierTypes.DISEASE_PNEUMONIA);
41 }
EStaminaMultiplierTypes
Definition StaminaHandler.c:2

◆ OnDeactivate()

void OnDeactivate ( PlayerBase player)
inlineprotected
44 {
45 player.DecreaseDiseaseCount();
46
47 player.GetStaminaHandler().DeactivateRecoveryModifier(EStaminaMultiplierTypes.DISEASE_PNEUMONIA);
48 player.GetStaminaHandler().DeactivateDepletionModifier(EStaminaMultiplierTypes.DISEASE_PNEUMONIA);
49
50 player.SetTemporaryResistanceToAgent(eAgents.INFLUENZA, TEMPORARY_RESISTANCE_TIME);
51 }
const int TEMPORARY_RESISTANCE_TIME
Definition Pneumonia.c:11

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

◆ OnTick()

void OnTick ( PlayerBase player,
float deltaT )
inlineprotected
59 {
61
62 player.AddHealth(-healthLoss);
63
64 float heavyBreathChance = player.GetSingleAgentCountNormalized(eAgents.INFLUENZA);
65
67 {
68 player.GetSymptomManager().QueueUpPrimarySymptom(SymptomIDs.SYMPTOM_GASP);
69 }
70 }
Definition EnMath.c:7
const float HEALTH_LOSS_PNEUMONIA
Definition Pneumonia.c:9
static proto int RandomInt(int min, int max)
Returns a random int number between and min [inclusive] and max [exclusive].
static float RandomFloat01()
Returns a random float number between and min [inclusive] and max [inclusive].
Definition EnMath.c:126

Перекрестные ссылки HEALTH_LOSS_PNEUMONIA, Math::RandomFloat01() и Math::RandomInt().

Поля

◆ AGENT_THRESHOLD_ACTIVATE

const int AGENT_THRESHOLD_ACTIVATE = 1150
private

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

◆ AGENT_THRESHOLD_DEACTIVATE

const int AGENT_THRESHOLD_DEACTIVATE = 1100
private

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

◆ HEALTH_LOSS_PNEUMONIA

const float HEALTH_LOSS_PNEUMONIA = 0.1
private

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

◆ STAMINA_DEPLETION_MULTIPLIER

const float STAMINA_DEPLETION_MULTIPLIER = 1.3
private

Используется в StaminaHandler::Init().

◆ STAMINA_RECOVERY_MULTIPLIER

const float STAMINA_RECOVERY_MULTIPLIER = 0.5
private

Используется в StaminaHandler::Init().

◆ TEMPORARY_RESISTANCE_TIME

const int TEMPORARY_RESISTANCE_TIME = 600
private

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


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