public interface IEvent { }

public interface IEventHandler<TEvent> where TEvent : IEvent
{
    void HandleEvent(TEvent eventData);
}

public struct ApplicationFocusEvent : IEvent
{
    public bool HasFocus;
}

public struct SceneLoadEvent : IEvent
{
    public string SceneName;
    public float Progress;
}

public abstract class EventHandler<TEvent> : IEventHandler<TEvent> where TEvent : IEvent
{
    public void HandleEvent(TEvent eventData)
    {
        OnEvent(eventData);
    }

    protected abstract void OnEvent(TEvent eventData);
}
