Refine start menu difficulty and preview workflow
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
# Project Guidelines
|
||||
|
||||
## UI Preview Tool
|
||||
|
||||
When editing the start menu, pause menu, or level intro UI, generate a real preview image before judging layout changes.
|
||||
|
||||
Use [tools/render_menu_preview.py](tools/render_menu_preview.py) instead of relying on mental layout or ad-hoc screenshots. The tool renders the actual SDL scene and saves a PNG from the real renderer.
|
||||
|
||||
Typical command:
|
||||
|
||||
```bash
|
||||
/home/enne2/dev/mice/.venv/bin/python tools/render_menu_preview.py \
|
||||
--output /tmp/mice_start_preview.png \
|
||||
--screen start \
|
||||
--difficulty normal \
|
||||
--resolution 1280x720
|
||||
```
|
||||
|
||||
Supported screens:
|
||||
|
||||
- `start`
|
||||
- `pause`
|
||||
- `level_intro`
|
||||
|
||||
Useful flags:
|
||||
|
||||
- `--difficulty easy|normal|hard`
|
||||
- `--resolution WIDTHxHEIGHT`
|
||||
- `--output /path/to/file.png`
|
||||
- `--seed N` for deterministic previews
|
||||
- `--animation-ms N` to choose the GIF frame timestamp for the start menu
|
||||
|
||||
Workflow when touching menu layout:
|
||||
|
||||
1. Edit the menu code.
|
||||
2. Run the preview tool for the relevant screen.
|
||||
3. Inspect the generated PNG.
|
||||
4. Iterate until spacing and readability are correct.
|
||||
|
||||
The preview tool is intended for fast visual feedback and should be preferred before launching a full interactive game session for menu-only changes.
|
||||
Reference in New Issue
Block a user