Skip to content

Field of View: let the toy appear in any cell at 150 ms - #242

Merged
acrosman merged 2 commits into
mainfrom
feat/199-toy-any-cell
Oct 26, 2026
Merged

acrosman merged 2 commits into
mainfrom
feat/199-toy-any-cell

Conversation

@acrosman

Copy link
Copy Markdown
Owner

Summary

Fixes #199. When the display time (SOA) reaches 150 ms or faster, the cat toy can appear in any cell except the kitten's center cell. Before that, it stays on the outer ring, as it does today.

What changed

  • game.js: new ANY_CELL_SOA_MS = 150 and isAnyCellPlacementForCurrentSoa(). createTrialLayout() passes the result to buildTrialLayout, which skips the edge filter when it is true. createPracticeTrial() still uses edge placement, so the tutorial is unchanged.
  • How to Play panel and the "Levels and Scoring" tutorial step now say the toy can appear anywhere around the kitten at the fastest speeds.
  • app/games/field-of-view/CLAUDE.md documents the threshold.

Testing

  • New tests steer Math.random across every candidate slot. Just above 150 ms, the toy lands only on the 16 edge cells of the 5×5 grid. At or below 150 ms, it can land on all 24 non-center cells.
  • npm run lint is clean. npm run test:coverage passes (2227 tests).

Review notes

  • The threshold is inclusive (<= 150), matching the 300 ms grid-size rule. Because of the 16.67 ms steps, the first SOA it applies to is 149.93 ms.
  • The tutorial screenshot was not retaken. It shows a 3×3 board, where every non-center cell is already on the edge.

Signed: Claude Code, on behalf of Aaron Crosman

🤖 Generated with Claude Code

acrosman and others added 2 commits October 25, 2026 19:06
Below ANY_CELL_SOA_MS (150 ms) the peripheral toy is no longer limited
to the outer ring of the grid; it can land in any cell except the
kitten's center cell. The tutorial practice trial keeps edge placement.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Update the How to Play panel, the levels tutorial step, and the game's
CLAUDE.md for the toy appearing anywhere at the fastest speeds.

Fixes #199

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@acrosman
acrosman merged commit bd40c12 into main Oct 26, 2026
7 checks passed
@acrosman
acrosman deleted the feat/199-toy-any-cell branch October 26, 2026 00:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Field of View: Move second image into more locations

1 participant