private void ApplyHealing() { playerHealth.Heal((config as SelfHealConfig).GetHealAmount()); // TODO: consider making it a percent of maximum health heal AudioSource audioSource = playerHealth.GetAudioSource(); audioSource.clip = config.GetRandomSoundClip(); audioSource.Play(); }
public void RegenerateHealth() { int healthToRegenerate = myHealthSystem.GetMaxHealth() - myHealthSystem.GetCurrentHealth(); if (healthToRegenerate > 0 && currentVitality >= healthRegenCost) { myHealthSystem.Heal(1); UpdateVitalityAmount(-healthRegenCost); UpdateVitalityBar(); } }
private void HealCharacter() { healthSystem.Heal((config as HealingEffectConfig).GetHealingPoints()); }
private void Heal(GameObject target) { HealthSystem health = GetComponent <HealthSystem>(); health.Heal((config as SelfHealConfig).GetExtraHealth()); }