Walls r1: one-way sight — per-viewer filter + ONEWAY fault #58

Closed
opened 2026-11-19 21:48:24 +01:00 by SirStone · 2 comments
Owner

Part of #52

Goal

the vision fan skips a sight-blocking one-way wall for a viewer on its seeing side — it blocks only the blind side — by one sign test against the (-dy,dx) normal, after the radius cull; the wall list stays hoisted and viewer-independent; movement stays two-way; explored and tiles differ by side and never shrink.

Acceptance criteria

  • one_way preset + sight_dir left/right; flipping swaps direction without moving endpoints.
  • Explored cells/tiles on the blind side never cross the wall, seeing side does (positive control).
  • A flip never un-explores a cell or revokes a tile.
  • Leak checker and tile oracle apply their own independent side test (never the server's vision code); blind-side 0.5 px band is maybe.
  • New ONEWAY fault hook (drops sight_dir in player-facing computation) caught as exactly ONEWAY.
  • Standing: full nimble + node test suites green on a clean checkout; no existing test weakened or skipped; behaviour proven at the approved seams (WS black-box, leak checker + fault builds, schema-7 migration fixture).

User stories covered

19, 20, 21, 22, 47, 48, 49, 50, 62

Proven at

  • WS black-box (one-way script, tiles).
  • Leak checker + fault build.

Notes

  • Size: M.
  • Blocked by: #55 (can run in parallel with W4/W5).
  • Story 62's marker clause is proven in W7.
Part of #52 ## Goal the vision fan skips a sight-blocking one-way wall for a viewer on its seeing side — it blocks only the blind side — by one sign test against the (-dy,dx) normal, after the radius cull; the wall list stays hoisted and viewer-independent; movement stays two-way; explored and tiles differ by side and never shrink. ## Acceptance criteria - `one_way` preset + `sight_dir` left/right; flipping swaps direction without moving endpoints. - Explored cells/tiles on the blind side never cross the wall, seeing side does (positive control). - A flip never un-explores a cell or revokes a tile. - Leak checker and tile oracle apply their own independent side test (never the server's vision code); blind-side 0.5 px band is maybe. - New `ONEWAY` fault hook (drops `sight_dir` in player-facing computation) caught as exactly ONEWAY. - Standing: full nimble + node test suites green on a clean checkout; no existing test weakened or skipped; behaviour proven at the approved seams (WS black-box, leak checker + fault builds, schema-7 migration fixture). ## User stories covered 19, 20, 21, 22, 47, 48, 49, 50, 62 ## Proven at - WS black-box (one-way script, tiles). - Leak checker + fault build. ## Notes - Size: M. - Blocked by: #55 (can run in parallel with W4/W5). - Story 62's marker clause is proven in W7.
SirStone added the ready-for-agentenhancement labels 2026-11-19 21:48:24 +01:00
SirStone added a new dependency 2026-11-19 21:48:29 +01:00
Author
Owner

Built on main as 9fcbe88 (rebased onto 0f3aa23, #56 preserved: geometryWalls(sc, forSight) still applies the secretgap hook and now also maps sight_dir).

  • geometry: WallDir/Wall.sightDir, blindTo (sign of cross(b-a, viewer-a) against the (-dy,dx) normal; left names the blind side), inline fan filter after the radius cull. Movement never reads it: ruleWall maps no direction, so a one-way wall blocks both ways.
  • vision: computePolys uses geometryWalls(..., forSight = true); LEAK_FAULT=oneWay drops sight_dir in the player-facing fan.
  • leakcheck: own side test (never imports vision.nim) for the fan and the clear-segment oracle, ONEWAY class matched against the sight_dir-dropped fan; scenario gains a one-way wall the subject sees across.
  • tools/oneway.test.mjs: two sides (blind/seeing), own tile oracle and sweep, flip with fixed endpoints, monotone explored/tiles, two-way move refusal, restart; registered in the tiles accept group.
  • fault.test.mjs: oneWay -> exactly ONEWAY; clean build passes (positive control).
  • TESTING 10.3 #58 markers moved to built; DESIGN 5.8 mechanism sentence corrected (the fan blocks on the blind side, skips on the seeing side).

Suites on the rebased tree: nimble test -y all pass; node --test --test-concurrency=1 tools/*.test.mjs 126/126 pass, 0 fail, 0 skipped. Test builds used a lane-local XDG_CACHE_HOME nimcache.

Built on main as 9fcbe88 (rebased onto 0f3aa23, #56 preserved: `geometryWalls(sc, forSight)` still applies the `secretgap` hook and now also maps `sight_dir`). - geometry: `WallDir`/`Wall.sightDir`, `blindTo` (sign of `cross(b-a, viewer-a)` against the `(-dy,dx)` normal; `left` names the blind side), inline fan filter after the radius cull. Movement never reads it: `ruleWall` maps no direction, so a one-way wall blocks both ways. - vision: `computePolys` uses `geometryWalls(..., forSight = true)`; `LEAK_FAULT=oneWay` drops `sight_dir` in the player-facing fan. - leakcheck: own side test (never imports `vision.nim`) for the fan and the clear-segment oracle, ONEWAY class matched against the sight_dir-dropped fan; scenario gains a one-way wall the subject sees across. - tools/oneway.test.mjs: two sides (blind/seeing), own tile oracle and sweep, flip with fixed endpoints, monotone explored/tiles, two-way move refusal, restart; registered in the `tiles` accept group. - fault.test.mjs: `oneWay` -> exactly ONEWAY; clean build passes (positive control). - TESTING 10.3 #58 markers moved to built; DESIGN 5.8 mechanism sentence corrected (the fan blocks on the blind side, skips on the seeing side). Suites on the rebased tree: `nimble test -y` all pass; `node --test --test-concurrency=1 tools/*.test.mjs` 126/126 pass, 0 fail, 0 skipped. Test builds used a lane-local `XDG_CACHE_HOME` nimcache.
Author
Owner

Corrected inverted blind-side sentence; behaviour unchanged (see #47)

Corrected inverted blind-side sentence; behaviour unchanged (see #47)
Sign in to join this conversation.