dacha
    Preparing search index...

    Class UIBridge

    Loads your game interface and runs it together with the game.

    Pass a loader in resources under UIBridge.systemName. The loader returns a module with onInit and onDestroy, see LoadUIFn. The system calls onInit with UIOptions when the world is ready, and onDestroy when the world is destroyed.

    const engine = new Engine({
    config,
    systems: [UIBridge, ...gameSystems],
    components: [...gameComponents],
    assets: [],
    resources: {
    [UIBridge.systemName]: {
    loadUI: () => import('./ui'),
    },
    },
    });

    Game UI

    Hierarchy (View Summary)

    Index
    systemName: string

    The name the configuration uses for the system.

    DefineSystem sets it, so a game usually does not assign it.