mirror of
https://github.com/jcreek/CosmicClash.git
synced 2026-09-13 15:52:04 +00:00
perf(ship): merge non-tinted hull meshes into one node
Hull/Canopy/EngineGlowL/EngineGlowR are runtime-baked into one ArrayMesh in _ready via SurfaceTool.append_from, dropping 4 MeshInstance3D children to 1 (Nose/TailFin stay separate, they're retinted per-team). Skipped in headless mode like the goal/arena_boundary visual builds, since physics only cares about CollisionShape3D. All 6 source surfaces (hull, canopy, engine_l x2, engine_r x2) carry distinct materials, so this doesn't literally cut draw calls 6 to 3 as TODO.md assumed — Godot still issues one draw call per surface regardless of node count. The real win is scene-tree/transform overhead, not batching.
This commit is contained in:
@@ -25,7 +25,6 @@ Bugs found in an adversarial review. None are gameplay- or physics-affecting, so
|
||||
|
||||
## Performance
|
||||
|
||||
- [ ] Merge the four non-tinted ship meshes (Hull/Canopy/EngineGlowL/R) into one — 6 draw calls per ship down to 3. Irrelevant at 1v1; 36 calls before VFX at 3v3.
|
||||
- [ ] Name collision layers in `project.godot` and assign them — nothing configures `collision_layer`/`collision_mask` today, so every body tests against every other.
|
||||
- [ ] Measure `nebula_dust.gdshader`'s per-fragment depth-texture sample across 500 large soft billboards before adding more particle work.
|
||||
- [ ] Bake `ArenaBoundary`'s ~160 runtime-generated `CollisionShape3D` nodes into the scene. Costs a load hitch on every arena entry and repeats in every parallel headless training env. **Blocked on the trained-bot decision below** — `arena_boundary.gd:235` notes this geometry is what the shipped policies were fitted against, so the bake must be verified byte-identical.
|
||||
|
||||
Reference in New Issue
Block a user