aboutsummaryrefslogtreecommitdiff
path: root/crates/fparkan-runtime/src/player_weapon.rs
diff options
context:
space:
mode:
authorValentin Popov <valentin@popov.link>2026-11-25 21:50:05 +0300
committerValentin Popov <valentin@popov.link>2026-11-25 21:50:05 +0300
commitf50fb0dcae975cd964b7606cc7248d9e771abb2c (patch)
tree6a3656b2f8ed66d4904e655a8d23bd64b6ea59c5 /crates/fparkan-runtime/src/player_weapon.rs
parent574a1c02ba88b5205437cca3c0b0c29fe1afa945 (diff)
downloadfparkan-f50fb0dcae975cd964b7606cc7248d9e771abb2c.tar.xz
fparkan-f50fb0dcae975cd964b7606cc7248d9e771abb2c.zip
fix(production): use Control energy budgets for factory work
Factories now run the recovered Control resource-budget pass on its own randomized clock before Behavior task updates. Paid production reads its current work-device E00 value, including the local power reserve and allocation, instead of gating full speed on any clan generation. The clock redraws jitter on every accepted frame and uses a separate Control RNG. Initial phase, seed and ordering with other owners remain explicit approximations. Budget failures preserve the table and are counted per owner. Original DLL calls verify the budget callbacks, strict deadline, per-call RNG, forced update and inactive baseline. A live class-3 factory executes the same budget with the default 250 ms setting. Licensed regressions cover an empty factory power reserve, subsequent generator capture, four completed paid orders, the Behavior task deadline and scripted warbot/transport/builder births. Workspace fmt/check/tests and release build pass. All 29 stock missions run 900 seconds without script or new budget stops. Stock mission 28 accepts and completes a free and then a paid player order in the Vulkan-validation window.
Diffstat (limited to 'crates/fparkan-runtime/src/player_weapon.rs')
0 files changed, 0 insertions, 0 deletions