20 lines
662 B
C#

namespace Syntriax.Engine.Core.Abstract;
/// <summary>
/// Represents a behaviour that any object in the game might use to interact with itself or other objects.
/// </summary>
public interface IBehaviour : IEntity, IActive, IHasBehaviourController, IHasStateEnable
{
/// <summary>
/// Event triggered when the priority of the <see cref="IBehaviour"/> changes.
/// </summary>
event PriorityChangedEventHandler? OnPriorityChanged;
/// <summary>
/// The priority of the <see cref="IBehaviour"/>.
/// </summary>
int Priority { get; set; }
delegate void PriorityChangedEventHandler(IBehaviour sender, int previousPriority);
}