Engine²
Open-source game engine written in C++.
Loading...
Searching...
No Matches
EventSystem.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "core/Core.hpp"
5
6namespace Event::System {
7
8template <typename TScheduler> inline void ProcessEvents(Engine::Core &core)
9{
10 auto &eventManager = core.GetResource<Resource::EventManager>();
11 eventManager.ProcessEvents<TScheduler>();
12}
13
14} // namespace Event::System
The core is the place where all the data of the engine is stored. It contains the registry (entities)...
Definition Core.hpp:33
TResource & GetResource()
Get a reference of a resource.
Definition Core.inl:14
Thread-safe event manager for registering, queuing, and dispatching events.
Definition EventManager.hpp:23
void ProcessEvents(void)
Process all queued events for a specific scheduler.
Definition EventManager.hpp:146
Definition EventSystem.hpp:6
void ProcessEvents(Engine::Core &core)
Definition EventSystem.hpp:8