ReviewOS

stacks/the-settlers-iii-remake

[S3-041] Complete timber, forestry, sawmill, and stone production

#43
Open chris opened this 9 days ago ·
9 days ago

S3-041: Complete timber, forestry, sawmill, and stone production

Parent and ownership

Parent epic: https://github.com/stacksjs/the-settlers-iii-remake/issues/8 Source owner: stacksjs/the-settlers-iii-remake. Master roadmap: https://github.com/stacksjs/the-settlers-iii-remake/issues/4.

Problem and observable result

Travel to actual finite resources. Implement planting and verified processing. Respect working areas and doorstep limits.

The current application is a browser prototype. Passing the Riverlands campaign does not establish original-game or native parity. This issue is complete only when its stated behavior has retained evidence.

Evidence and interfaces

Production consumes physically delivered inputs and staffed work. Bounded output inventories create backpressure. Controls change production and carrier decisions rather than settlement totals directly.

Pin the inspected revisions and fixture hashes in the implementation evidence. Original-game observations govern rules and timing. JSettlers is implementation evidence, not an authoritative balance specification. Unknown values remain explicitly unverified.

Acceptance criteria

  • Travel to actual finite resources.
  • Implement planting and verified processing.
  • Respect working areas and doorstep limits.
  • The visible result agrees with the underlying simulation or platform state, including failure paths.
  • Tests exercise the maintained public interface and retain reproducible fixtures or execution receipts.

Test matrix

  • Exhaust a wood or stone working area.
  • Recover production after transport resumes.
  • Exercise invalid input, cancellation or interruption, and repeated execution where this interface permits them.
  • Verify determinism/conservation for simulation changes and resource ownership/disposal for platform changes.
  • Run owning-repository lint, relevant type checks and tests. Capture actual native output for native capability claims.

Scope constraints

Implement this behavior as a complete verifiable slice. Do not silently expand into adjacent tickets or substitute simplified gameplay. Keep the shared TypeScript simulation, shared stx signals, and ts-css conventions. Native gameplay and HUD must not depend on a WebView. HomeOS reuse must not introduce a kernel dependency into the game. Existing unrelated edits and authored guidance must be preserved.

Blocked by

Upstream release and adoption

Application behavior belongs here. If a reproduction identifies a framework defect, repair and release its owning source first, update Stacks where affected, then install the verified packages here.

No node_modules edits, copied runtimes, generated-source string patches, fabricated globals, successful no-op implementations, or skipped release gates. Push tested conventional commits as Chris to the owning origin/main without coauthor trailers or force pushes.

Completion evidence

  • Implementation commits and relevant upstream issue links.
  • Exact checks and results, fixture hashes, and screenshots/native execution evidence where applicable.
  • Published package versions, downstream lockfile identity, and release receipts when affected.
  • Remaining limitations stated explicitly. Partial work does not close this issue.
14 hours ago

The reachable-planting defect is implemented and deployed. #233 is completed; this parent remains open.

Implementation d49b4ee now filters for reachable planting tiles before applying the nearest-eight limit. Foresters and cultivated crops can therefore recover when the nearest free tiles are across water but usable land remains in their working area. The engineering rules profile is version 0.18.0, with the preceding 0.17.0 behavior retained for historical replay. Receipt.

Exact main fb77ab1c8e811717b9b3a170406916b78cc5dfc5 passed full CI: 23 browser suites, 1,031 successful steps. The original diagnostics artifact 13122086974 matched GitHub SHA256 b92a04a675221fff83478b7b5c3fa4c89d1dd6b4aa1290cc6da98e88ebdf03fc, size 47,770 bytes and all ZIP CRCs. Unit acceptance passed 497 tests / 94,684 assertions, with lint, types, assets and production build checks. Protected production deployment and its real smoke checks passed; rollback was correctly skipped.

The first planting CI attempt exposed a separate campaign checkpoint assertion racing the real save acknowledgement. fb77ab1 replaced fixed sleeps/immediate checks with the existing bounded acknowledgement polling after controlled real Web Lock contention reproduced the race. The original failed artifact and reproduction are retained in the checkpoint receipt. No storage runtime or acceptance budget was changed.

Original Gold durations, radii, balance and native game acceptance are still unverified. This establishes the recorded engineering behavior and its browser delivery, without completing this parent's original-observation requirements.

9 days ago

Progress (S3-041, still open)

Woodcutters walk to the nearest tree in their working area, fell it and carry the log home; foresters plant saplings that grow into trees; stonecutters work finite granite; the sawmill turns logs into planks. Work radii and durations are placeholders.

Implementation: resources/game/engine/production.ts, workforce.ts, logistics.ts; tests in tests/unit/engine-economy.test.ts and tests/unit/engine-audit.test.ts.

Evidence base for this update (all on main, authored as Chris):

  • 3ca4847 deterministic session, rules profile, routing, goods, carriers, construction, production, territory, visibility, saves and replays
  • da2a104 reference building geometry and the delivery livelock fix
  • b2efc1f the browser game on the engine, expanded original-media import
  • 7b1cc36 worlds from decoded original maps
  • a495e7a, 0a3ff46, 0e7889e, e5c1a53, f3b71ce, ed1dc8f controls, missions, render scene, save migration, checkpoints, audit and statistics

Checks: ./buddy lint (0 problems), bun run typecheck (app, tools, stx), ./buddy test --unit (106 tests, 0 failures), bun run assets:verify, bun run content:verify, and the production browser scenario. CI passed on 0e7889e and 9e2ba7c (which contains f3b71ce), including the production Chrome check.

Rule values are the roman-engineering 0.2.0 profile (resources/game/engine/rules.ts). Every value names its evidence class: manual candidates (M) from the pinned manual, reference-remake geometry (E), or placeholders (U) that name their owning issue. qualificationGaps() lists them and the profile cannot qualify a release. Adopting observed original values remains with S3-002/S3-007; nothing here is an original-executable observation.

8 days ago

Retained a fresh desktop browser economy playthrough from ordinary starting goods, using native clicks and keys without private state reads, injected resources or demolition refunds. Execution receipt, committed in ed19489.

Built and staffed a woodcutter, forester, stonecutter and sawmill; aligned the timber working areas and set the stonecutter area on visible granite. Continued through a farm, mill, waterworks and bakery. A pioneer expanded western land so the farm could be placed.

The sawmill and bakery reached bounded full output buffers. Marking planks and bread for storage through the real Transport menu let carriers clear them, and production resumed. At the 36:15 in-game save, cumulative production included 33 logs, 28 planks, 10 stone and 24 bread. Starting logs can explain only 8 planks, so the other 20 planks came from newly gathered timber. All seven recorded resource rows obeyed starting + made - used = physical stock. A real reload retained the ledgers, and logging produced one more log before the restored run was paused.

Raw accessibility trees and screenshots are retained by hash in the receipt; original-media rasters remain outside public artifacts. This is evidence for the implemented Roman engineering profile over the recorded interval. It does not verify original Gold durations/balance, indefinitely sustainable whole-economy behavior, all food chains or native presentation. Issue 43 remains open for its remaining original-observation criteria.

Final main CI is successful on exact source ed194896a7128a0f2a4027bde69f558ddd2cbdfb. Independently downloaded the original diagnostics artifact 12596993813 (16,026 bytes), matched GitHub SHA-256 e5d9e7a04ae43f7e33693b52dedb12fac3a258fdc7af4def978433aa15928dad, verified every ZIP CRC, and confirmed all 313 successful browser steps with zero recorded console errors, failed requests or collection errors.

6 days ago

A fresh production-browser playthrough built and staffed a woodcutter, forester, stonecutter and sawmill through normal controls. After restoring that settlement across the framework upgrade, the woodcutter reported an exhausted working area. Moving its area to visible trees resumed harvesting: logs rose from 7 to 16 and its inspector showed 7/8 output and “Working.” The settlement was saved again.

The execution receipt records the seed, completed buildings, working areas, stock observations and private capture checksums. The local production browser gate also passed its existing working-area and production regressions.

This adds recovery evidence for the current engineering profile. Original Gold timings and balance remain unobserved, so this issue stays open.

Sign in to comment on this issue.