Add a level screen
Read src/Game/Level/README.md; model it on ExampleLevel.cs (screen with UI) or QuitLevel.cs (logical, no UI).
Ask for the level name if not given. Then:
Add the enum value in Enum/Level.cs (e.g.
Menu).Create the screen class in
src/Game/Level/<Name>Level.cs:- namespace
Game.Game.Level; - a
Control(or otherNode) implementingILevelObserver; - constructor takes
IGameLeveland, if it has UI, the owning module's factory; - set
ProcessMode = ProcessModeEnum.Alwaysif it must react while the tree is paused; - build UI in
_Ready(or host a module UI via its factory); - implement
OnLevelOppened(newLevel, oldLevel)— typicallyVisible = newLevel == Enum.Level.<Name>.
- namespace
Register it in GameLevel._Ready: create it,
_observers.Add(...),AddChild(...)(usually under theCanvasLayer).Switch to it from anywhere with
_gameLevel.OpenLevel(Enum.Level.<Name>).Verify with the
verifyskill.
A screen only decides when to show. Feature data/logic/layout belong in a module (add-module), not in the screen.