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

Protected Member Functions

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

Protected Attributes

float m_NextEvent
 
float m_Time
 

Static Private Attributes

static const int AGENT_THRESHOLD_ACTIVATE = 1
 
static const int AGENT_THRESHOLD_DEACTIVATE = 100
 
static const int EVENT_1_INTERVAL_MIN = 20
 
static const int EVENT_1_INTERVAL_MAX = 40
 

Detailed Description

Definition at line 1 of file Contamination.c.

Member Function Documentation

◆ ActivateCondition()

bool ContaminationStage1Mdfr::ActivateCondition ( PlayerBase player)
inlineprotected

Definition at line 25 of file Contamination.c.

26 {
27 return (player.GetSingleAgentCount(eAgents.CHEMICAL_POISON) >= AGENT_THRESHOLD_ACTIVATE && player.GetSingleAgentCount(eAgents.CHEMICAL_POISON) < AGENT_THRESHOLD_DEACTIVATE);
28 }
eAgents
Definition EAgents.c:3
static const int AGENT_THRESHOLD_DEACTIVATE
static const int AGENT_THRESHOLD_ACTIVATE

References AGENT_THRESHOLD_ACTIVATE, and AGENT_THRESHOLD_DEACTIVATE.

Referenced by DeactivateCondition().

◆ DeactivateCondition()

bool ContaminationStage1Mdfr::DeactivateCondition ( PlayerBase player)
inlineprotected

Definition at line 41 of file Contamination.c.

42 {
44 }
bool ActivateCondition(PlayerBase player)

References ActivateCondition().

◆ GetDebugText()

override string ContaminationStage1Mdfr::GetDebugText ( )
inlineprotected

Definition at line 20 of file Contamination.c.

21 {
22 return ("Activate threshold: " + AGENT_THRESHOLD_ACTIVATE + "| " + "Deativate threshold: " + AGENT_THRESHOLD_DEACTIVATE);
23 }

References AGENT_THRESHOLD_ACTIVATE, and AGENT_THRESHOLD_DEACTIVATE.

◆ Init()

override void ContaminationStage1Mdfr::Init ( )
inlineprotected

Definition at line 12 of file Contamination.c.

13 {
14 m_ID = eModifiers.MDF_CONTAMINATION1;
17 m_SyncID = eModifierSyncIDs.MODIFIER_SYNC_CONTAMINATION;
18 }
int m_ID
ID of effect, given by SEffectManager when registered (automatically done when playing through it)
Definition Effect.c:49
eModifierSyncIDs m_SyncID
float m_TickIntervalActive
float m_TickIntervalInactive
eModifierSyncIDs
const int DEFAULT_TICK_TIME_INACTIVE
const int DEFAULT_TICK_TIME_ACTIVE
eModifiers
Definition eModifiers.c:2

References DEFAULT_TICK_TIME_ACTIVE, DEFAULT_TICK_TIME_INACTIVE, m_ID, m_SyncID, m_TickIntervalActive, and m_TickIntervalInactive.

◆ OnActivate()

void ContaminationStage1Mdfr::OnActivate ( PlayerBase player)
inlineprotected

Definition at line 30 of file Contamination.c.

31 {
32 //player.IncreaseDiseaseCount();
34 }
static const int EVENT_1_INTERVAL_MAX
static const int EVENT_1_INTERVAL_MIN
Definition EnMath.c:7
static float RandomFloatInclusive(float min, float max)
Returns a random float number between and min [inclusive] and max [inclusive].
Definition EnMath.c:106

References EVENT_1_INTERVAL_MAX, EVENT_1_INTERVAL_MIN, m_NextEvent, and Math::RandomFloatInclusive().

◆ OnDeactivate()

void ContaminationStage1Mdfr::OnDeactivate ( PlayerBase player)
inlineprotected

Definition at line 36 of file Contamination.c.

37 {
38 //player.DecreaseDiseaseCount();
39 }

◆ OnTick()

void ContaminationStage1Mdfr::OnTick ( PlayerBase player,
float deltaT )
inlineprotected

Definition at line 46 of file Contamination.c.

47 {
48 /*
49 m_Time += deltaT;
50
51 if ( m_Time >= m_NextEvent )
52 {
53 player.GetSymptomManager().QueueUpPrimarySymptom(SymptomIDs.SYMPTOM_COUGH);
54 m_Time = 0;
55 m_NextEvent = Math.RandomFloatInclusive( EVENT_1_INTERVAL_MIN, EVENT_1_INTERVAL_MAX );
56 }
57 */
58 }

Member Data Documentation

◆ AGENT_THRESHOLD_ACTIVATE

const int ContaminationStage1Mdfr::AGENT_THRESHOLD_ACTIVATE = 1
staticprivate

Definition at line 3 of file Contamination.c.

Referenced by ActivateCondition(), and GetDebugText().

◆ AGENT_THRESHOLD_DEACTIVATE

const int ContaminationStage1Mdfr::AGENT_THRESHOLD_DEACTIVATE = 100
staticprivate

Definition at line 4 of file Contamination.c.

Referenced by ActivateCondition(), and GetDebugText().

◆ EVENT_1_INTERVAL_MAX

const int ContaminationStage1Mdfr::EVENT_1_INTERVAL_MAX = 40
staticprivate

Definition at line 7 of file Contamination.c.

Referenced by OnActivate().

◆ EVENT_1_INTERVAL_MIN

const int ContaminationStage1Mdfr::EVENT_1_INTERVAL_MIN = 20
staticprivate

Definition at line 6 of file Contamination.c.

Referenced by OnActivate().

◆ m_NextEvent

float ContaminationStage1Mdfr::m_NextEvent
protected

Definition at line 9 of file Contamination.c.

Referenced by OnActivate().

◆ m_Time

float ContaminationStage1Mdfr::m_Time
protected

Definition at line 10 of file Contamination.c.


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