public void RemoveHealthComponent(BaseHealth health) { _initialHeath -= health._initialHeath; _currentHealth = (currentHealth - health._initialHeath > 0) ? currentHealth - health._initialHeath : _currentHealth; HealthAdded?.Invoke(this, EventArgs.Empty); }
public void AddHealthComponent(BaseHealth newHealth) { _initialHeath += newHealth._initialHeath; _currentHealth += newHealth._initialHeath; HealthAdded?.Invoke(this, EventArgs.Empty); }