diff options
| author | Valentin Popov <valentin@popov.link> | 2026-11-26 08:42:38 +0300 |
|---|---|---|
| committer | Valentin Popov <valentin@popov.link> | 2026-11-26 08:42:38 +0300 |
| commit | 2f75b9792c98c4d32b0349810080dd226357b505 (patch) | |
| tree | a49b82684c095bf2b54523262cdf3edf4b3ce824 /apps/fparkan-game/src/main.rs | |
| parent | 5844c9b0f4216da47cf03894b34f9a150fd5b170 (diff) | |
| download | fparkan-2f75b9792c98c4d32b0349810080dd226357b505.tar.xz fparkan-2f75b9792c98c4d32b0349810080dd226357b505.zip | |
feat(render): throw detached chassis nodes as fragments
Pass the depleted node to an authored Op10 with a built-in mesh request. Reuse its existing draw ranges for the flight and keep the hull alive. The fixed-camera fixture shows the heavy track section separate and rotate after impact.
Diffstat (limited to 'apps/fparkan-game/src/main.rs')
| -rw-r--r-- | apps/fparkan-game/src/main.rs | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/apps/fparkan-game/src/main.rs b/apps/fparkan-game/src/main.rs index 0d134277..ae1e80a5 100644 --- a/apps/fparkan-game/src/main.rs +++ b/apps/fparkan-game/src/main.rs @@ -11404,9 +11404,9 @@ impl StaticVulkanApp { fparkan_runtime::take_unit_destruction_effects(engine), control_clock_ms, self.audio.as_mut(), - |index, origin| { + |mesh, origin| { debris::capture( - index, + mesh, origin, &self.dynamic_component_geometry, &self.mesh, @@ -11967,6 +11967,11 @@ impl StaticVulkanApp { &self.component_pose_buffers, &self.mesh, renderer, + |range| { + self.destruction_effects + .as_ref() + .is_some_and(|effects| effects.keeps_range(range)) + }, )?; } if !self.removed_mission_roots.is_empty() || self.boarded_hero_index.is_some() { |
