using System; using Content.Server.GameObjects.Components.Damage; using Content.Shared.GameObjects.Components.Damage; using Robust.Shared.Interfaces.GameObjects; namespace Content.Server.Interfaces.GameObjects.Components.Damage { public interface IDamageableComponent : IComponent { event EventHandler DamageThresholdPassed; ResistanceSet Resistances { get; } /// /// The function that handles receiving damage. /// Converts damage via the resistance set then applies it /// and informs components of thresholds passed as necessary. /// /// Type of damage being received. /// Amount of damage being received. /// Entity that damaged this entity. /// Mob that damaged this entity. void TakeDamage(DamageType damageType, int amount, IEntity source, IEntity sourceMob); /// /// Handles receiving healing. /// Converts healing via the resistance set then applies it /// and informs components of thresholds passed as necessary. /// /// Type of healing being received. /// Amount of healing being received. /// Entity that healed this entity. /// Mob that healed this entity. void TakeHealing(DamageType damageType, int amount, IEntity source, IEntity sourceMob); } }