You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(scene): pause a scene, so its systems stop while a pause menu is open #521
Which package or utils is this feature request for?
scene
Feature
A game can't pause a scene. Its systems keep running until the scene is unloaded. A pause menu is the common case: breakout (NanoForge-dev/examples#18) opens a pause scene over its level, and the level's ball and paddles must stop moving. Library systems such as components-systems move2D have no off switch, so the game wraps each of them in its own system that checks a pause flag.
Ideal solution or implementation
@nanoforge-dev/scene pauses a scene: its systems (those an EcsScene registered, ecs-scene.ts) are skipped while it is paused, its entities stay. For example ctx.scenes.pause(id) / resume(id), or a child scene that pauses its parent while it is open.
Alternative solutions or implementations
A pause flag in each library system (not wanted: every library would need it).
Activity