Skip to content

W83 — Buildings Get Dirty, Wear Out, and Break #354

Description

@The-Running-Dev

A resort that is left unattended degrades, and one that is looked after does not. Buildings get dirty from use and from litter, wear down over time, and eventually break and stop serving — which is the whole reason a player hires cleaners and the reason quality affects where guests choose to go. Today cleanliness moves only from unresolved litter, and wear never moves at all, so a resort is exactly as good on its thousandth tick as on its first.

Done when

  • W83.1 For one building receiving deltas from every source in the same tick, the five sources are applied in the contract's stated order — service, litter, incident, staff, policy — summed, then clamped once to 0..100. Asserted with a case where applying the same set in a different order, or clamping between sources, would give a different result.
  • W83.2 Wear moves, and wear reaching zero changes an open or closed building to broken; a broken building serves nobody and is not a candidate. Cleanliness reaching zero never closes a building on its own — asserted as a negative case.
  • W83.3 Cleaning increments the cleaned-litter counter by the amount actually removed, independently of any definition effect, and an incident amount reaching zero resolves the occurrence with its transition effects run exactly once — asserted by a repeated tick that must not run them twice.
  • W83.4 building.meter.changed is emitted and declared; the batch-grain audit carries status transitions and does not carry per-tick meter steps, asserted by the returned row count over a long batch.
  • W83.5 advance_ticks n serializes byte-identically to any split of that batch across a degradation-to-broken sequence.
  • W83.6 The two committed world-graph replay outcomes either stay byte-identical or the change is recorded as intended with the differing fields named in the pull request. Unlike W81 and W82, this one is not predicted either way: the MVP campaign already has a litter incident.
  • W83.7 npm run typecheck, npm run lint and npm test pass from src/engine/.

Agent instructions

Run /slice W83.

  • Scope and criteria: design/30-slices.md § W83 @ 6fd30e04106b4db4db7614faa0e474ff1b160405
  • Signatures: design/12-world-graph-kind.md §4, §10, §12, §13
  • Out of scope here: repair as a player action or a staff task kind (contract amendment); balance values for drift rates (content, belongs with Sun Trap); guest opinion changes driven by quality

Stop conditions and procedure: .claude/commands/slice.md. Not restated here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    sliceA W-numbered vertical delivery slice from design/30-slices.md

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions