Add MrGameEng.UI module integrating Myra

scene.UseUI() creates a per-scene Myra Desktop and registers
UiRenderSystem last in the draw phase (UI on top, window pixels).
GameHost now exposes itself as a Game service (Myra needs the instance;
useful for games too). Myra was picked over Gum/ImGui for the
FontStashSharp ecosystem fit, pipeline-free assets and maturity; its
internal SpriteBatch use is a documented exception to the engine rule.

Sample: on-screen HUD replaces window-title-only stats — live FPS label,
music volume slider and scene-switch buttons on both scenes.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Leonid Pershin
2026-06-11 04:51:12 +03:00
co-authored by Claude Fable 5
parent a3e6d3bb0a
commit af319d1276
12 changed files with 159 additions and 8 deletions
+3 -1
View File
@@ -18,7 +18,9 @@
- Physics2D (выбор библиотеки: Aether.Physics2D / своя)
- Tilemap (поддержка Tiled)
- Particles
- UI
- UI: загрузка MML-разметки Myra через AssetManager + хендлы в кодогенераторе
- UI: рендер Myra через наш батчер (`IMyraRenderer`), если UI станет узким местом по draw call'ам
- DevTools-модуль на ImGui.NET: инспектор сущностей, дебаг-панели
- Бенчмарки BenchmarkDotNet для систем (сейчас производительность контролируется стресс-сценой)
- Spatial hash для culling на очень больших мирах (если профилирование покажет необходимость)
- Параллельная запись вершин (Parallel.For по чанкам), если упрёмся в CPU на ещё больших сценах