@modoki/engine / index / ManagerDef
Interface: ManagerDef
A Manager is a plain singleton implementing this shape. registerManager only wires its lifecycle + owned actions — other code calls its methods by importing the singleton directly (no service locator).
Extended by
Managers
actions?
optionalactions?:Record<string,UIActionDef|UIActionHandler>
Named UIAction handlers owned by this manager (same shape systems use). Registered on activate, removed on deactivate.
games?
optionalgames?:string[]
Game scope only: active-game ids to match; omit = every game.
name
name:
string
scenes?
optionalscenes?:string[]
Scene scope only: path substrings to match; omit = every scene.
scope?
optionalscope?:ManagerScope
Default 'scene'.
dispose()?
optionaldispose(ctx?):void
ctx carries the world the manager was operating against (on a scene swap this is the OLD world, still alive until just after dispose runs) so a dispose can tear down world-bound state on the correct world. Optional.
Parameters
ctx?
Returns
void
init()?
optionalinit(ctx):void|Promise<void>
Parameters
ctx
Returns
void | Promise<void>