3 static const int AGENT_THRESHOLD_ACTIVATE = 100;
4 static const int AGENT_THRESHOLD_DEACTIVATE = 20;
8 Error(
"[ERROR] :: WoundInfectionMdfr is deprecated.");
16 static const int AGENT_THRESHOLD_ACTIVATE = 1;
17 static const int AGENT_THRESHOLD_DEACTIVATE = 250;
18 static const int AGENT_THRESHOLD_FEVER = 250;
20 static const int PAIN_EVENT_INTERVAL_MIN = 18;
21 static const int PAIN_EVENT_INTERVAL_MAX = 26;
23 protected float m_NextEvent;
24 protected float m_Time;
35 override string GetDebugText()
37 return (
"Activate threshold: "+AGENT_THRESHOLD_ACTIVATE +
"| " +
"Deativate threshold: "+AGENT_THRESHOLD_DEACTIVATE);
40 override protected bool ActivateCondition(
PlayerBase player)
42 if( player.GetSingleAgentCount(
eAgents.WOUND_AGENT) >= AGENT_THRESHOLD_ACTIVATE && !player.GetModifiersManager().IsModifierActive(
eModifiers.MDF_WOUND_INFECTION2))
52 override protected void OnActivate(
PlayerBase player)
54 player.IncreaseDiseaseCount();
55 m_NextEvent =
Math.RandomFloatInclusive( PAIN_EVENT_INTERVAL_MIN, PAIN_EVENT_INTERVAL_MAX );
58 override protected void OnDeactivate(
PlayerBase player)
60 player.DecreaseDiseaseCount();
63 override protected bool DeactivateCondition(
PlayerBase player)
65 return !ActivateCondition(player);
68 override protected void OnTick(
PlayerBase player,
float deltaT)
73 if (
m_Time >= m_NextEvent )
75 player.GetSymptomManager().QueueUpPrimarySymptom(SymptomIDs.SYMPTOM_PAIN_LIGHT);
77 m_NextEvent =
Math.RandomFloatInclusive( PAIN_EVENT_INTERVAL_MIN, PAIN_EVENT_INTERVAL_MAX );