3 private float m_LastHealthLevel;
4 private float m_LastBloodLevel;
16 override bool ActivateCondition(
PlayerBase player)
22 override bool DeactivateCondition(
PlayerBase player)
27 override void OnTick(
PlayerBase player,
float deltaT)
30 float blood = player.GetHealth(
"GlobalHealth",
"Blood");
31 float health = player.GetHealth(
"GlobalHealth",
"Health");
33 float healthdelta =
Math.AbsInt(health - m_LastHealthLevel);
34 if (health < m_LastHealthLevel) healthdelta = -healthdelta;
36 m_LastHealthLevel = health;
38 float blooddelta =
Math.AbsInt(blood - m_LastBloodLevel);
39 if (blood < m_LastBloodLevel) blooddelta = -blooddelta;
41 m_LastBloodLevel = blood;