Skip to content

@modoki/engine / index / initGameManagersFor

Function: initGameManagersFor() ​

initGameManagersFor(gameId, scenePath): Promise<void>

Set the active game and activate game-scoped managers whose games filter matches it. gameId === null clears the active game (activates nothing). Awaitable so SceneManager can let async init finish before loadScene resolves. Idempotent for already-active managers. Pair with disposeActiveGameManagers when the game actually changes — this function only activates, it never disposes.

Parameters ​

gameId ​

string | null

scenePath ​

string

Returns ​

Promise<void>

Built with Modoki.