using System; namespace Torch.API.Event { /// /// Attribute indicating that a method should be invoked when the event occurs. /// [AttributeUsage(AttributeTargets.Method)] public class EventHandlerAttribute : Attribute { /// /// Events are executed from low priority to high priority. /// /// /// While this may seem unintuitive this gives the high priority events the final say on changing/canceling events. /// public int Priority { get; set; } = 0; /// /// Specifies if this handler should ignore a consumed event. /// /// /// If is true and the event is cancelled by a lower priority handler this handler won't be invoked. /// /// public bool SkipCancelled { get; set; } = false; } }