diff options
| author | Valentin Popov <valentin@popov.link> | 2026-11-26 00:59:10 +0300 |
|---|---|---|
| committer | Valentin Popov <valentin@popov.link> | 2026-11-26 00:59:10 +0300 |
| commit | 8a0f8a449dc3b80c5348c60b54982a71a45b0da2 (patch) | |
| tree | eba762334ad47e48a08bb0531fec7ebf63fb73f0 /crates/fparkan-runtime/src/lib.rs | |
| parent | 8ac763f7bfda827016d17c66372d02b85d5a9bb5 (diff) | |
| download | fparkan-8a0f8a449dc3b80c5348c60b54982a71a45b0da2.tar.xz fparkan-8a0f8a449dc3b80c5348c60b54982a71a45b0da2.zip | |
feat(diagnostics): retain combat chronology and failures by object
Collect shot and destruction counts with first/last mission clocks in the
shared window and headless combat loop. Preserve original IDs and slot
generations after deletion, including projectiles whose shooter has died.
Count preparation, launch, pose and impact failures by object and cause;
separate an unavailable damage result from an error and log its first target.
Validation: workspace fmt/check/tests, release build, licensed stock AutoDemo
through its first destruction, and stock AutoDemo in the window. All 29 stock
900-second simulation summaries and first-event times match the prior build.
Rechecked missions 8 and 19 after separating damage result categories.
Window/headless first shots were 18404/18533 ms and first kills 25947/25933 ms.
The report exposes UnsupportedNodeLifecycle on the factory root in mission 19
and unavailable damage results on building nodes in mission 8. Their behavior
is unchanged. Original five-minute chronology and broader G7 acceptance remain
open; this diagnostic task identifies concrete runtime paths for further work.
Diffstat (limited to 'crates/fparkan-runtime/src/lib.rs')
| -rw-r--r-- | crates/fparkan-runtime/src/lib.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/crates/fparkan-runtime/src/lib.rs b/crates/fparkan-runtime/src/lib.rs index 103c669e..6311683b 100644 --- a/crates/fparkan-runtime/src/lib.rs +++ b/crates/fparkan-runtime/src/lib.rs @@ -51,6 +51,8 @@ mod clan_area_strength; mod clan_build_limits; mod clan_building_queries; mod clan_clock; +mod combat_report; +pub use combat_report::{CombatObject, CombatOccurrences, CombatReport}; mod control_profile; mod control_resources; mod mobile_budget; @@ -2993,6 +2995,7 @@ pub struct SimulationReport { pub patrol_speeds: PatrolSpeedReport, pub control_profiles: ControlProfileReport, pub mobile_budget: MobileBudgetReport, + pub combat: CombatReport, /// Approximate clan strength queries, grouped by caller and target clan. pub script_strength_queries: Vec<(usize, u16, u64)>, pub script_capture_queries: Vec<(usize, u64)>, @@ -3074,6 +3077,7 @@ pub fn simulate_mission_report( patrol_speeds: PatrolSpeedReport::default(), control_profiles: ControlProfileReport::default(), mobile_budget: MobileBudgetReport::default(), + combat: CombatReport::default(), script_strength_queries: Vec::new(), script_capture_queries: Vec::new(), script_attack_queries: Vec::new(), @@ -3201,6 +3205,7 @@ pub fn simulate_mission_report( } if let Some(combat) = &engine.autodemo_combat { report.weapon_poses = combat.pose_report().clone(); + report.combat = combat.report.clone(); } for problem in loaded.clan_ai_events.pending_problems() { *report |
