namespace PkmnLib.Dynamic.Events;
///
/// The event hook of a battle. This is used to hook into the battle and get notified when something
/// happens that a front-end might want to know about.
///
public class EventHook
{
///
/// The event handler that is called when the event is triggered.
///
public event EventHandler? Handler;
///
/// Triggers the event, calling the handler with the given data.
///
public void Invoke(IEventData data)
{
Handler?.Invoke(this, data);
}
}