Split The code is public; the app answers only to the crew.
Your crosshair: colour, size, gap, thickness and a dot, remembered like the rest #121
Check · Review · Land · Live done — Landed and live in production.
The crosshair is a setting now, and the defaults are byte-for-byte the crosshair this game already drew.
shipped merged
Sign in to join this conversation.
new above
offline
The crosshair is a setting now, and the defaults are byte-for-byte the crosshair this game already drew.
src/client/crosshair.tsis the whole of the geometry: a style plus the gun's current inaccuracy in, four segments and an optional dot out, with colour resolved from a table of six names — the only strings that can reachctx.strokeStyle.hud.tslost its hard-coded loop and strokes whatever comes back.parseSettingsgains acrosshairgroup guarded field by field the waydifficultyis, andparseCrosshairis exported so the controls send their own values back through the same boundary as stored JSON; acs.settingsblob written before this group existed loads with today's crosshair and nothing else disturbed (tested). Six controls — colour, size, gap, thickness, dot, dynamic — sit in a collapsed Crosshair disclosure in the menu and again in the pause overlay, server-rendered with their ranges read out ofCROSSHAIR_LIMITS, so a field can never offer a number the parser would throw away; the two toggles carry their state in their text as well asaria-pressed, so nothing changes width.Worth looking at in the preview: open Crosshair in the menu, set gap 12 / thickness 4 / dot on, play, and watch the arms open as you run and close as you stop — then turn Dynamic off and see them hold still. The pause overlay's copy changes the same number mid-match and both panels stay in step.
hud.test.tspins the default segments, colour and line width against the recording context (its recorder now snapshotsstrokeStyle,fillStyleandlineWidth, which is why that file's diff is larger than the feature).bun run checkpasses: 493 tests, no type errors; the page still answers in ~19 ms locally.What I chose not to do: no crosshair preview swatch, no outline or per-weapon styles, no T-shape or per-arm lengths — the issue asked for six settings and stopping there kept the diff small enough to land ahead of the other
hud.tswork. No new dependencies.🤖 Generated with Claude Code
Closes #81