()
| 6 | * Get a reference to the current scene. |
| 7 | */ |
| 8 | export function useScene(): Scene { |
| 9 | const scene = SceneStack.at(-1); |
| 10 | if (!scene) { |
| 11 | throw new Error('The scene is not available in the current context.'); |
| 12 | } |
| 13 | return scene; |
| 14 | } |
| 15 | |
| 16 | export function startScene(scene: Scene) { |
| 17 | SceneStack.push(scene); |
no outgoing calls
no test coverage detected