From d4e008fe33337494c0a28d9e35da9986a7dd42c7 Mon Sep 17 00:00:00 2001 From: Valentin Popov Date: Wed, 25 Nov 2026 19:20:42 +0400 Subject: fix(ai): schedule clan cycles with native jitter and logical time Use a separate AI CRT stream for the 7000 + rand() % 1000 ms cycle. Require a strictly later deadline, reschedule late callbacks from actual arrival time, and advance script time by seven seconds per cycle. Count executed cycles by clan; retain explicit initial-phase and RNG-order gaps. Validated the native RNG through ai.dll and the timer in the running original. Workspace fmt/check/tests and all 29 stock 900-second reports pass. A stock-start mission-28 window ran through warbot and transport production and successive laboratory projects. This is not full G7 chronology acceptance; candidate properties for 65/69 remain stubbed. --- apps/fparkan-game/src/script_coverage.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'apps/fparkan-game') diff --git a/apps/fparkan-game/src/script_coverage.rs b/apps/fparkan-game/src/script_coverage.rs index 2a0ee337..c5032c54 100644 --- a/apps/fparkan-game/src/script_coverage.rs +++ b/apps/fparkan-game/src/script_coverage.rs @@ -21,6 +21,9 @@ pub(super) fn log_script_init(engine: &Engine, mission: &str) { } pub(super) fn log_clan_ai_stops(report: &SimulationReport) { + for &(clan, count) in &report.clan_ai_clock_ticks { + eprintln!("sim_coverage script_clan_clock_approx={count} clan={clan}"); + } for &(clan, entries, selected, count) in &report.clan_research_catalogs { eprintln!("sim_coverage script_research_catalog_approx={count} clan={clan} entries={entries} selected={selected}"); } -- cgit v1.2.3