Files
GameJamDungeon/Zennysoft.Game.Ma.Implementation/Components/IHealthComponent.cs

25 lines
567 B
C#

using Chickensoft.Collections;
namespace Zennysoft.Ma.Adapter;
public interface IHealthComponent : IEntityComponent
{
public IAutoProp<int> CurrentHP { get; }
public IAutoProp<int> MaximumHP { get; }
public event Action? HealthReachedZero;
public event Action? DamageTaken;
public bool AtFullHealth { get; }
public void Heal(int healAmount);
public void Damage(int damageAmount);
public void SetCurrentHealth(int health);
public void SetMaximumHealth(int health);
public void RaiseMaximumHP(int raiseAmount, bool restoreHP = false);
}