diff options
| author | Valentin Popov <valentin@popov.link> | 2026-11-14 20:03:39 +0300 |
|---|---|---|
| committer | Valentin Popov <valentin@popov.link> | 2026-11-14 20:03:39 +0300 |
| commit | 58910ebe71100617abf6523827e2b04351709de9 (patch) | |
| tree | 3acb94399e5c5131ba183ee837fddbcaf42e3614 /apps/fparkan-game/src/script_coverage.rs | |
| parent | 77ab4031f5c140ae5bce4096abab0552a0675ef9 (diff) | |
| download | fparkan-58910ebe71100617abf6523827e2b04351709de9.tar.xz fparkan-58910ebe71100617abf6523827e2b04351709de9.zip | |
feat(ai): dispatch periodic clan problem scripts
Runs the supported Problems0 prefix for AI clans and counts every stop by clan, event and instruction. Single.01 now reaches the native scenario body and identifies Handler(49) as the next unsupported command. Existing defensive behavior remains active.
Diffstat (limited to 'apps/fparkan-game/src/script_coverage.rs')
| -rw-r--r-- | apps/fparkan-game/src/script_coverage.rs | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/apps/fparkan-game/src/script_coverage.rs b/apps/fparkan-game/src/script_coverage.rs index 1cf1f544..0b0eea99 100644 --- a/apps/fparkan-game/src/script_coverage.rs +++ b/apps/fparkan-game/src/script_coverage.rs @@ -1,4 +1,6 @@ -use fparkan_runtime::{loaded_mission_script_bundles, Engine, MissionScriptInitExecution}; +use fparkan_runtime::{ + loaded_mission_script_bundles, Engine, MissionScriptInitExecution, SimulationReport, +}; pub(super) fn log_script_init(engine: &Engine, mission: &str) { for bundle in loaded_mission_script_bundles(engine).unwrap_or_default() { @@ -17,3 +19,12 @@ pub(super) fn log_script_init(engine: &Engine, mission: &str) { } } } + +pub(super) fn log_clan_ai_stops(report: &SimulationReport) { + for (stop, count) in &report.clan_ai_event_stops { + eprintln!( + "sim_coverage script_clan_ai_stops={count} clan={} script={} event={} instruction={} reason={}", + stop.clan_index, stop.script_path, stop.event_index, stop.instruction_index, stop.reason, + ); + } +} |
