ReviewOS

stacks/the-settlers-iii-remake

Initialize growth timers for immature objects in scenario maps

#234
Closed chris opened this 14 hours ago ·
14 hours ago

Immature objects placed through describeMap never mature in a new session. createState starts with an empty growth queue, and only worker planting creates timers, so initial scenario saplings, grain fields and vines remain immature indefinitely despite their own growth rules.

Parent: https://github.com/stacksjs/the-settlers-iii-remake/issues/43 Source owner: stacksjs/the-settlers-iii-remake.

Reproduced through the maintained public describeMap, createSession and advance interfaces on fb77ab1c8e811717b9b3a170406916b78cc5dfc5, Bun 1.4.4. A declarative 64x64 grass map places one immature object at (44,44), clear of the starting castle at (16,16), with no settlers. After the engineering profile's respective due ticks, sapling remains sapling at tick 2401, field remains field at 1601 and vine remains vine at 10801. All three expected-maturation assertions fail, while accounting audits stay clean. The retained external regression reports 0 pass / 3 fail / 15 assertions in 506 ms. No live state was mutated and no original installation is required.

Acceptance:

  • Schedule initial immature map objects once, using their existing declared growth intervals, after scenario setup has cleared building sites.
  • Do not schedule mature/static objects or growth for objects removed by scenario placement. Keep due-time and tile ordering deterministic.
  • Preserve complete saved growth queues and deadlines through restore and replay. Do not reconstruct queues when opening a saved session.
  • Freeze published 0.18.0 with its exact digest and preserve historical initial-map and save/replay behavior through an explicit versioned policy.
  • Exercise sapling, field and vine maturation boundaries; mature and site-cleared exclusions; mid-growth save/restore; replay; determinism; clean audits, through the public session interface.
  • Retain source/rules identities, red/green results and relevant full unit, lint, type and build evidence before completion.

This fixes an internal lifecycle contradiction in the authored engineering profile. It does not change or verify original Gold durations, resource quantities, balance, initial object classifications or native gameplay. Parent #43 remains open for its full fidelity criteria. No relation to residence or pioneer behavior is claimed.

13 hours ago

Implemented and normally pushed as Chris, without coauthors: c0cd9dd.

New sessions schedule surviving immature map objects after scenario buildings clear their sites. The existing growth intervals and canonical due/tile order apply. Restore retains the saved queue and deadline. Rules 0.19.0 opts into this behavior; frozen 0.18.0 retains its original digest and historical save/replay behavior.

The public-session regression failed before the source correction and now passes all nine checks, including sapling, field and vine boundaries, mature/cleared exclusions, restore, replay and determinism. Full local validation passed: 506 unit tests, 94,743 assertions, lint, application/tools/STX types, production build and original asset verification. Independent Standards and Spec reviews found no actionable issues. The durable receipt retains source/rules identities and the original environmental prerequisite failures.

Exact-source CI 41433583106 is running. This issue remains open until its actual hosted results are qualified. Parent #43 remains open for its wider criteria. No original Gold timing, object classification or native gameplay claim is made.

12 hours ago

Completed on main as c0cd9dd, authored and committed as Chris without coauthors. The source receipt retains the red/green reproduction, exact rules/source identities and local checks.

Exact CI 41433583106 passed on its first attempt: 506 unit tests, 94,743 assertions, lint, types, build, assets and all 1,031 browser steps. Original diagnostic artifact 13137235273 is 47,652 bytes, SHA256 2c17ebf18ec280f56e71ceba36de74b565c0a0c599b87b9dbd6861cd10b0a706. Its API digest, all 45 safe ZIP entries/CRCs, retained file identities and report/capture metadata were independently verified. Original raster bytes remain withheld; capture metadata is not visual inspection.

Protected production deployment 41437989453 actually deployed both main and API at this exact commit. Its public smoke passed, and an independent repeat also passed all ten checks, including real WebP decoding and the signed-out play redirect. Rollback was correctly skipped after success.

Rules 0.19.0 enables initial object growth; frozen 0.18.0 retains its original digest, save and replay behavior. This closes the bounded lifecycle correction. Parent #43 remains open for its wider criteria, including unobserved original Gold behavior. No native gameplay or Gold timing qualification is claimed.

Sign in to comment on this issue.