EventManager - mjfalkenstein/GameProject GitHub Wiki
The EventManager can be used to notify other systems of events. Events can be dispatched, and all systems that have subscribed to that type of event will have a callback invoked to process that event.
void EventManager::subscribe<T>(std::function<void(const T&)> handler)
Subscribes a callback to be invoked every time an event of type T is dispatched.
void EventManager::dispatch<T>(const T& event)
Invokes all callbacks that have been subscribed to events of type T