diff options
| author | Valentin Popov <valentin@popov.link> | 2026-11-25 21:50:05 +0300 |
|---|---|---|
| committer | Valentin Popov <valentin@popov.link> | 2026-11-25 21:50:05 +0300 |
| commit | f50fb0dcae975cd964b7606cc7248d9e771abb2c (patch) | |
| tree | 6a3656b2f8ed66d4904e655a8d23bd64b6ea59c5 /docs/appendices/script-vm.md | |
| parent | 574a1c02ba88b5205437cca3c0b0c29fe1afa945 (diff) | |
| download | fparkan-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 'docs/appendices/script-vm.md')
| -rw-r--r-- | docs/appendices/script-vm.md | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/appendices/script-vm.md b/docs/appendices/script-vm.md index 71051e28..5c1ad71e 100644 --- a/docs/appendices/script-vm.md +++ b/docs/appendices/script-vm.md @@ -2056,6 +2056,14 @@ RNG. На третьем порог меняется и шаг выполняеÑ #### Доставка игровых часов в Control +В GOG `Control.dll` (SHA-256 +`bcb86318089028548a178b03a21accdce15df0cc85ddd91674cf3c2f55012c6e`) +ресурсная часть RVA `0xbcf0` вызывает бюджет RVA `0x2d340` и у обычного +завода класса `3` в «Двух крепостях». Живой экземпляр использует активную +ветвь и настройку периода `250` мс. Интерфейс устройств, сохранённый у +Behavior, находится на `Control owner + 0x0c`; это важно при чтении часов +и множителей: смещения самой Control считаются от владельца. + Статическая цепочка относится к GOG-модулям `World3D.dll` (SHA-256 `17e4a3089b2583a8cf2356c9db0390b1aba138356a09130d79b4e7e4791da61e`), `AniMesh.dll` (`65659bf67f20e5be77d67a5b2f59968f61b94293143807fa59ca451c560c4f7e`) |
