StaticsystemThe name the configuration uses for the system.
DefineSystem sets it, so a game usually does not assign it.
StaticwithLists the system in EngineOptions.systems together with its dependencies: classes and functions from the game code that cannot live in the configuration. The system receives them as the second argument of its constructor.
The dependencies of the system.
A binding to put into EngineOptions.systems.
Loads your game interface and runs it together with the game.
Pass a loader with
UIBridge.with({ loadUI }). The loader returns a module withonInitandonDestroy, see LoadUIFn. The system callsonInitwith a UIContext when the world is ready, andonDestroywhen the world is destroyed.To give the interface settings, extend the class and declare fields with DefineField. You edit them in the system's settings, and the interface reads them from UIContext.options.
Example
Example
See
Game UI