feat(db): typed wall storage, marker_seen and height backfill (#53)

This commit is contained in:
2026-11-19 22:03:11 +01:00
parent 6a443b4ec0
commit c1b1e9cf91
10 changed files with 551 additions and 45 deletions
+2 -2
View File
@@ -21,11 +21,11 @@ proc geometryWalls*(sc: SceneRec): seq[Wall] =
## The scene's walls as the vision code sees them: an open door does not block (5.1).
result = newSeqOfCap[Wall](sc.walls.len)
for w in sc.walls:
result.add Wall(a: w.a, b: w.b, door: w.kind == wkDoor, open: w.open)
result.add Wall(a: w.a, b: w.b, door: w.door, open: w.open)
proc ruleWall*(w: WallRec): Wall =
## The same wall as the move rules see it (they need `door`/`open` to know what blocks).
Wall(a: w.a, b: w.b, door: w.kind == wkDoor, open: w.open)
Wall(a: w.a, b: w.b, door: w.door, open: w.open)
proc ruleToken*(sc: SceneRec, t: TokenRec): moverules.Token =
moverules.Token(pos: t.pos, owner: t.owner,