using System;
using Chernobyl.Event;
namespace Chernobyl.Game.Destruction
{
///
/// Represents an object that can be killed or destroyed such as life forms,
/// buildings, etc.
///
public interface IDestroyable : Chernobyl.Destruction.IDestroyable
{
///
/// A 0 to 1 value that represents the health of this instance. If this
/// value is 0 then this instance has been destroyed. If this value is
/// 1 then this instance has full health.
///
/// Thrown if the value
/// set on this property is below zero or above 1.
float Health { get; set; }
///
/// The maximum amount of health this instance can have. This value is
/// NOT clamped between 0 and 1 but cannot go below 0 (for example it
/// could be 100). Note that the minimum amount of health is always 0.
///
/// Thrown if the value
/// set on this property is zero or below.
float MaxHealth { get; set; }
///
/// An event that is raised when this instance is damaged. The
/// type passed as the event
/// argument represents the old value and the new value of the
/// property.
///
event EventHandler> Damaged;
///
/// An event that occurs when this instance gains health. The
/// type passed as the event
/// argument represents the old value and the new value of the
/// property.
///
event EventHandler> Healed;
///
/// An event that is raised when this object has been fully restored
/// back to life. In other words, when is zero and
/// then becomes a number greater than zero. The
/// type passed as the event
/// argument represents the old value (always 0) and the new value of
/// the property.
///
event EventHandler> Revived;
}
}