11 override bool ActivateCondition(
PlayerBase player)
13 float m_MaxBlood = player.GetMaxHealth(
"GlobalHealth",
"Blood");
14 if ( player.GetHealth(
"GlobalHealth",
"Blood") <= m_MaxBlood )
29 override bool DeactivateCondition(
PlayerBase player)
31 float m_MaxBlood = player.GetMaxHealth(
"GlobalHealth",
"Blood");
32 if ( player.GetHealth(
"GlobalHealth",
"Blood") >= m_MaxBlood )
42 override void OnTick(
PlayerBase player,
float deltaT)
44 float regen_modifier_water = GetRegenModifierWater( player.GetStatWater().Get() );
45 float regen_modifier_energy = GetRegenModifierEnergy( player.GetStatEnergy().Get() );
46 float blood_regen_speed =
PlayerConstants.BLOOD_REGEN_RATE_PER_SEC * regen_modifier_water * regen_modifier_energy;
52 player.AddHealth(
"",
"Blood", blood_regen_speed * deltaT );
55 float GetRegenModifierWater(
float water)
58 int water_level =
m_Player.GetStatLevelWater();
71 float GetRegenModifierEnergy(
float energy)
74 int energy_level =
m_Player.GetStatLevelEnergy();