mountHeadlessScene
mountHeadlessScene(
Scene,world?):Promise<MountedScene>
Mounts Scene in Node, with no page and nothing drawn: the physics
wasm loaded and every effect the components run settled, so the world
is ready to step when it returns. A scene that throws rejects. It mounts
on a dev world of its own unless handed one, as a room hands its own,
with the levels the last defineLevels call made where the world holds
none, as Game spawns its levels, and inside the components of the
plugins the world was made from, as Game nests them. Its reload
mounts the scene again and resolves once it has settled, which a room
calls in the step a restart raised the world’s SceneReloadsTrait and
waits for before its next step.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
Scene |
ComponentType |
world |
World |
Returns
Section titled “Returns”Promise<MountedScene>