From 29f9265e3e24b48baceb2747d1266990d2a54589 Mon Sep 17 00:00:00 2001 From: Daniel Covington Date: Thu, 3 Dec 2026 08:22:03 -0500 Subject: [PATCH] M2.1: people table and movement blocked by water and stone Co-Authored-By: Claude Opus 5.5 --- docs/manual-tests.md | 13 +- docs/toolchain.md | 1 + docs/verification-status.md | 2 +- project.json | 4 +- src/main.s | 9 +- src/people.inc | 283 ++++++++++++++++++++++++++++++++++++ tools/check-people.ps1 | 135 +++++++++++++++++ 7 files changed, 440 insertions(+), 7 deletions(-) create mode 100644 src/people.inc create mode 100644 tools/check-people.ps1 diff --git a/docs/manual-tests.md b/docs/manual-tests.md index 6c812c0..c94ad88 100644 --- a/docs/manual-tests.md +++ b/docs/manual-tests.md @@ -80,11 +80,18 @@ Setup: VICE x64sc, NTSC (-ntsc), warp off. Start: `pwsh -File tools/run.ps1 -Target c64` Steps: -1. Watch the visible dots for 30 seconds. +1. Run `pwsh -File tools/check-people.ps1` and note the result. +2. Start the program and wait for the map view. +3. Watch the visible dots for 30 seconds. Pay attention to dots near the blue pool and the grey stone patch. +4. Tap SPACE, wait for the new map, and watch the dots for another 10 seconds. Expected: -- Dots move at least once per second -- No dot enters blue or grey pixels +- `tools/check-people.ps1` prints `[PASS]`. +- About four light red dots are visible (16 people are spread over the four screens of the world; until scrolling arrives in M3 only the top-left screen is shown). +- Dots move at least once per second (each takes about 7 small steps a second and sometimes changes direction). +- No dot enters blue or grey pixels. A dot that reaches water or stone turns away. +- After SPACE, dots appear on the new map and keep moving. +- At M2.1 the dots are drawn straight into the visible buffer during vertical blank; small flicker or a missed frame is not a failure until M2.2 adds the buffer flip (MT2.2). Verifies: R2 diff --git a/docs/toolchain.md b/docs/toolchain.md index 9f8535d..477d16c 100644 --- a/docs/toolchain.md +++ b/docs/toolchain.md @@ -56,6 +56,7 @@ Starter configurations marked verified were exercised by the Foundry's automated - World generation reached its ready point (`MAP READY`) - C64 KERNAL reset vector at $FFFC (machine is in C64 mode) - World check: `pwsh -File tools/check-world.ps1` validates the tile data saved by the smoke test. +- People check: `pwsh -File tools/check-people.ps1` runs VICE headless (NTSC, warp) for 40,000,000 cycles, logs the people table at the `people_moved` hook every frame through the monitor, and checks that all 16 people stay inside the world, never stand on a water or stone tile, move at most one pixel per step, all move, and start spread over the four screens. Output: `build/check-people/`. ### How the smoke test works diff --git a/docs/verification-status.md b/docs/verification-status.md index eecbc49..a764fb8 100644 --- a/docs/verification-status.md +++ b/docs/verification-status.md @@ -12,7 +12,7 @@ manual = `pending`, `confirmed by user ()`, `problem reported ():