예제 #1
0
        public void RemoveHealth(float count)
        {
            float oldCount = health;

            health -= Mathf.Abs(count);
            health  = Mathf.Clamp(health, 0, maxHealth);
            if (!Mathf.Approximately(oldCount, health))
            {
                RavenhillEvents.OnPlayerHealthChanged(oldCount, health);
            }
        }