TrinyxEngine class
#include <Runtime/Core/Public/TrinyxEngine.h>
The Sentinel — main-thread owner of all engine subsystems.
Owns the SDL window, Vulkan context and memory, the render and audio subsystems, the job system, and the FlowManager. Does not own per-world data (Registry, JoltPhysics, LogicThread) — those live inside each WorldBase managed by the FlowManager.
Responsibilities:
- SDL event pumping (SDL requires events on the main thread).
- Window and GPU device lifetime.
- VulkanContext + VulkanMemory ownership shared across all worlds.
- Thread lifecycle management (Logic, Render, job workers).
- Frame pacing (timing only — the RenderThread is GPU-autonomous).
- FlowManager ownership and default-world caching.
Public static functions
- static auto Get() -> TrinyxEngine&
- Singleton accessor — one engine instance per process.
Public variables
- Callback<void, WorldBase*> OnPlayStarted
- Fired when Play (Local) is clicked in the editor.
- Callback<void> OnPlayStopped
- Fired when Stop (Local) is clicked in the editor.
- WorldBase* InputTargetWorld
- When set,
PumpEventswrites input to this world instead ofDefaultWorld.
Variable documentation
WorldBase* TrinyxEngine:: InputTargetWorld
When set, PumpEvents writes input to this world instead of DefaultWorld.