- RES 2 -> 3: phone screens now DOWNSCALE the canvas (crisp pixels) instead
of upscaling it (soft). Umpire-tap coords un-hardcoded from RES=2.
- Flatter lens: camZ 36 -> 42 with camF scaled per orientation (406/580) so
the PLAYER stays the same size — far-court zombies render ~25% bigger and
finally read as individuals from the baseline.
- Smoother animation: 4-frame walk cycles for both classic shamblers and the
runner's sprint (new sheets, same style anchor; z_a1-4, z_b1-4, z_f1-4).
Same cycle frequency — frames subdivide the stride. Render falls back to
2 frames per variant until its sheet loads.
- Tiered gore (GORE_MUL): the more advanced the zombie, the more absurd the
mess — classics 1x (base bumped 24 -> 30 particles), runner 1.8x, shield
2.5x, racket boss 3x, brute 4x (120 particles, a scatter of stains, an
instant size-3 mound).
Verified: fresh origin, canvas 1440px, umpire triple-tap works at RES 3,
all 4 anim frames cycle at the old stride rate, brute kill = 120 parts /
2 stains / size-3 pile, far-court lineup screenshot clearly readable,
portrait layout numbers correct (810x1440, camF 580), tennis 11/12,
no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
THE FREEZE (root cause found): the game-winning kill fires INSIDE the zombie
update loop — killZombie -> splatPoint -> gameOver -> sweepCourt guts the
zombies array mid-iteration, the loop reads zombies[i] === undefined, throws,
and the un-rescheduled RAF chain dies: a permanent hard freeze. Crowded courts
(later games, brutes) make the mid-loop game-winner likelier — hence 'freezes
around game 3 when the fat zombies arrive'. Fixed at the root (null guards in
every loop whose body can cascade into a sweep: zombie walk loop, meleeSwipe,
explode, pellet + extras inner loops) AND made frame() reschedule RAF FIRST so
no single bad frame can ever kill the loop again.
Aim awareness: the reticle now appears the moment the thumb lands (mag 0 =
auto-target the most advanced zombie, red lock immediately). A pure HOLD
(>250ms, no drag) releases into the auto-target serve; dragging aims as
before; the serve prompt switches to 'RELEASE TO SERVE / RELEASE FIRES THE
BOMB - DRAG BACK TO CANCEL' while aiming.
Duel presentation: the interlude now opens with a 2.4s intro beat — serving
blocked, centered card (SUDDEN DEATH / ONE POINT - THE LINES ARE LIVE / WIN
IT FOR THE NEXT TIN), and the palette lerps back to the TENNIS colors for
the duration of the duel (duelLerp, 0.8s each way) — order visibly restored,
then the rot returns.
Machine-gun steering: absolute now — the finger x IS the player x, zero lag
(was sign-quantized velocity). Clamped to what the camera can see
((W/2-14)/proj-scale — portrait's world bounds are wider than its viewport),
keyboard steering clamped the same during auto-fire.
Verified: the exact pre-fix crash scenario (game-winning kill mid-loop,
9 zombies + brute) survives and sweeps clean; intro blocks taps then the
duel plays; hold-release fired at the auto-lock and won a tin end-to-end;
screenshot shows tennis-green court + centered card + GAME 2; MG jumps
P.x to the finger in one frame, clamped; tennis 12/12; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Flick-to-aim was aim-by-faith — you learned where you aimed after the ball
was gone. Now, at a serveable pretoss, touching and dragging shows a LIVE
reticle (same mapping: direction + length = landing point); release serves
there. The magnet is finally visible: within zSnap the ring turns red and
rides the locked zombie (plus a marker over its head) — you see the lock
BEFORE you commit the tin.
- Context locked at touchstart: a movement drag started mid-rally never
morphs into a serve when the ball dies (sub-300ms releases still count
as the rapid flick re-serve — the Phase 1 cadence survives)
- Drag back home = cancel: no serve, the tin stays in stock
- Aimed (drag) serves commit specials at fixed 0.62 quality; the tap-toss
ritual keeps the PERFECT-timing power ceiling and the stock — placement
vs power is now a real choice
- Rally / horde / machine gun untouched: drag steers, flick swings
- Serve prompt: 'TAP TO SERVE - HOLD + DRAG TO AIM' / 'AIMED SERVES FIRE
THE BOMB - TAP KEEPS IT'
Verified with synthetic touch sequences: drag arms the reticle without
serving and it tracks the thumb; release serves at the marker with the bomb
committed; cancel keeps the tin; rally-started drags never morph; locked
reticle renders red on the zombie (screenshot); tennis 12/12; no console
errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Oliver's six complaints, addressed:
1. Opponent never came — a racket zombie now spawns on EVERY game you win
(if none alive); endHorde no longer double-spawns
2. No wave-cleared feeling — sweepCourt: at game end the surviving wave
collapses, every game gets a real beat (gameBeatT 1.6 / changeover 4.5),
and 'GAME N' announces the next wave when play re-arms
3. Serve-posture lockup during machine gun — root cause: any 'over' beat
expiring into setupPoint() -> pretoss during auto-fire (no movement outside
rally, no serving during horde/GUN). The over-expiry now returns auto-fire
modes to 'rally', never the serve loop
4. Forced bomb spending — specials commit ONLY on deliberate serves: flick
(or arrow-aimed keyboard serve) fires the tin, plain tap keeps it; serve
prompt teaches it ('FLICK FIRES THE BOMB - TAP KEEPS IT')
5. Auto-aim — free-aim: the flick vector maps to a landing point (length =
depth, up to 22m), zombies within zSnap 1.4 magnet the shot, otherwise the
ball lands exactly where flicked; taps keep the old auto-target assist;
flicks now also work at the toss apex
6. Zombies walking through you — option (a): touch is honest. eatenR 0.9
(brute +0.2) matches the visual sprite overlap
Phase 13 — SUDDEN DEATH interlude: court clear + un-dueled racket zombie +
about to serve -> 'Quiet, please. Play will resume.' / 'Sudden death.' One
point under REAL tennis rules (line calls live, the boss plays every ball,
spawns paused). Win (line call, double bounce, or regicide by any weapon) =
the next tin delivered on the spot; lose (out, or its return passes you) =
a game on their scoreboard + an instant 5-shambler surge. One duel per
opponent. New lines: play_resume.m4a, sudden_death.m4a.
Verified in browser: horde 'over' beat -> rally (lockup dead); game win ->
sweep + boss + beat -> SUDDEN DEATH chains naturally; duel lose path (GAME.
THEM., surge 5, scoreboard), no re-duel, fresh-boss duel, bomb regicide ->
tin on the spot; tap serve keeps stock, real touch-flick consumes + lands
at the flicked point, magnet snaps when near; eaten at 0.85m; tennis 11/12;
no console errors. PLAN.md/HANDOFF updated: plan v2 complete.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Deliveries cycle BOMB -> TRIPLE -> FIRE -> GUN (G.deliveries indexes the
ladder); one tin at a time, a fresh delivery replaces unspent stock. All
weapons stay one-thumb: the serve auto-consumes, zero new inputs.
- Triple serve (x3): one real serve fans two ballistic clones +-6deg (extras[]
in zombies.js — NOT the reverted rapid-fire: each fan costs a proper serve).
Side balls respect variant rules (wound brutes, clank off chairs, pass the boss)
- Flame ball (x3): kills on ANY contact regardless of pow, chair ignored,
full pierce (splatter pace tax undone), ember trail, white-hot render
- Machine gun (8s): horde auto-fire as a pickup — no serving, drag steers,
no assist, spawner keeps running, ammo bar drains on the HUD, then the
serve loop resumes
- HUD pips per type (black/yellow/orange) at the bomb slot; flash names the
tin ('NEW BALLS: FIRE')
Verified: ladder cycles across 5 deliveries; triple spawns 2 extras and the
fan kills flanked targets; pow-0.1 flame ball clears shambler+shield+brute in
one pass with TRIPLE KILL chaining; GUN tin arms at changeover, blocks taps,
streams pellets (kill in 5 frames), expires back to pretoss; tennis 11/12;
no weapon-flag leaks into tennis; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Spawn mix (pickVariant): roster grows one type per set — runner from set 1
game 3+ (12% slot, at most one alive, shriek on spawn = the fairness contract),
brute from set 2 (15%), shield from set 3 (15%); classics fill the rest
- Runner ('f'): 3.2x shamble speed, faster leg cycle; new shriek() synth in audio
- Brute ('g'): hp 2 vs splat-quality balls AND pellets, 0.55x speed, 0.75m target,
pushback-immune, 0.9m eaten radius, dies to double gore + size-2 pile, towers
at 1.5x height
- Shield ('s'): blocks front balls with the chair (clank, ball spent), the block
drops the chair for shieldDown 1.5s — any splat-quality ball kills in the
window (z_s3 staggered pose renders); chair recovers after; always dies to
bombs, melee, pellets
- TUNE: runnerSpeed 3.2, bruteHp 2, shieldDown 1.5
Verified in browser: per-variant stats; brute soft-ball immunity, 2-hit kill,
2-pellet kill, size-2 pile; shield block->window kill->chair recovery->blocks
again; melee kills f/s but not the racket boss; tier-2 spawn mix over 1500
spawns = 14/15/8/63%; all five sprites render with correct scale+occlusion;
tennis regression 11/12; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sheets generated with the existing zombie sheet as the style anchor (edit mode);
sliced to z_f1/2 (runner sprint), z_g1/2 (brute + net-post club), z_s1/2/3
(shield zombie, chair up / chair dropped stagger), x_tin (black new-balls tin).
assets/_slice.py is now committed (chroma-key + de-fringe + segmentation) so the
pipeline survives scratchpad wipes; HANDOFF updated.
Sprites are NOT wired into render.js yet — Phase 11 does that after Oliver
approves the sheets (plan's design checkpoint).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Deliveries are scheduled by the rules of tennis: game ballChangeFirst (3),
then every ballChangeEvery (4) games; the tin lands at the NEXT changeover
(a due tin survives hordes and even-game endings until a changeover comes)
- Fresh tin = bombMax (3) bombs; boy run + 'new balls, please' + NEW BALLS flash
- Shame rule: zombies took a game since the last delivery -> NO NEW BALLS,
slate wiped either way
- killMeter/bombEvery deleted from state/config/zombies
Verified: delivery at game 3 (bombs 3); due-but-even games hold the tin until
the next changeover; NO NEW BALLS withholds and clears shame; bomb serve still
arms and detonates; killMeter gone; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Camera shake (G.shake, decays over 0.35s; HUD stays steady via transform reset)
- One white flash frame (G.boomFlash overlay)
- Scorch crater: near-black stain the boys mop 10x slower — the lawn scars
- Hitstop 0.1 -> 0.18
- Umpire loses composure: 'Order. Order, please.' (new order.m4a), rate-limited
so bomb chains don't spam him
Verified: explode kills cluster of 4 (MASSACRE x4 chains), shake/flash set and
decay clean, 2nd bomb order-call suppressed, 1s of mopping erases blood (0.9->0)
but not the crater (1->0.84); screenshot mid-shake; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Spawn director: gap and court cap scale with games finished (runGames);
game 1 is three lonely shamblers, late runs approach zSpawnMin/zMaxCap
- Changeover after odd games: 4.5s forced breather, no spawns, no serving
(melee still works), boys mop, umpire calls 'Time.' (new time.m4a)
- 6 games = a set; set end launches the horde (replaces the splatGames>=2 trigger)
- Zombies taking a game sets shameGame (phase 9 withholds the delivery)
- Eaten = the run is over: GAME, SET, MASSACRE summary with games/sets survived
and best run (localStorage); HUD shows sets in splatter (SETS·GAMES PTS)
- spentBall() helper so dead-ball paths can't clobber a changeover's beat
- T surface: splatPoint + explode exposed for verify scripts
Verified: game-1 cap 3 held 25s; changeover blocks taps+spawns then resumes;
6 games -> set+horde -> racket zombie; runGames=6 tempo ~6 spawns/10s;
eaten writes best; tennis regression 11/12 CPU returns; no console errors.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Survive a horde and a racket zombie takes up residence on the far court
(variant 'r', one per horde survived) — the tennis rally skill lives on
inside zombie mode. It reuses the turned-CPU z_c sprite (already holds a
racket) and a slimmed copy of the tennis AI: holds station deep, chases a
ball laterally at TUNE.racketSpeed (2.8), and returns your SOFT shots
(pow < zSplatQ) as live lastHit:'O' balls with quality capped at
racketQMax (0.55) and racketFlub (0.2) whiffs. trySwing gained an
optional quality-cap arg (defaulted, so tennis is untouched).
It's a mini-boss with TUNE.racketHp (3): only splat-quality balls hurt it
(-1 hp, staggers the ball; the killing blow runs the full splatter). Soft
balls pass through for it to rally; melee and pellets don't touch it. Its
return that gets past your baseline is a point for THEM; you can rally it
back with the existing player hit. A red HP bar floats over its head.
Verified via window.T: endHorde spawns exactly one (hp 3, z 3.5); three
splat hits kill it (2→1→dead); a pow-0.3 ball is returned toward you; an
'O' ball past your baseline scores for THEM; melee spares the boss but
cleaves the shambler beside it; tennis still 12/11/12 and a normal
shambler is still one-shot; renders with its HP bar; no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Oliver's feedback on the feel pass:
1. Rapid-fire serving was way too easy. Reverted splatter serving to the
proper model: a tap does the toss ritual (apex timing = quality), a
flick is a quick aimed serve. Dropped the multi-ball barrage and
removed the extraBalls plumbing (array, update, render, hooks). Melee
swish and zombie homing stay. If multi-ball is wanted back, it should
require a proper serve per ball.
2. The player was stuck in the serve/swing pose when a horde started
(the triggering shot's pose lingered) — startHorde now clears it.
3. A horde re-triggered immediately: machine-gun kills scored points, so
games were won mid-horde and the next kill after it ended won another
game → instant new horde. A horde is now survival: it doesn't score
(splatPoint skipped while G.horde), so it can't chain. After a horde
you must win a full game again to summon the next.
Verified via window.T: a tap tosses (not an instant serve) and the full
toss→serve→rally completes; melee still kills adjacent shamblers; pose is
idle/-1 at horde start; no scoring during a horde and the next kill after
scores 15 without restarting it; tennis 11/12, bomb consume, homing all
still green; no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The x=±6 side spawns forced you to machine-gun targets off the edge of
your view/pellet lane. Now every horde zombie enters from the far
baseline across the court like the normal spawns, so the whole swarm
comes down in front of you.
Verified via window.T: a full 12s horde spawns ~29 zombies, all at the
far baseline (z -1.5..-2.5, |x| ≤ 4.9), zero side spawns.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
From Oliver's feedback round:
- Racket melee: any swish (tap) in splatter cleaves shamblers within
TUNE.meleeRange (1.7m) — a close-range survival tool. Works during a
horde too (tap = swish only, still no serve). The racket-zombie boss
(Phase 6, not built) is immune by design.
- Zombies home in on you: on YOUR half (z > netZ) they now drift toward
P.x instead of walking a straight lane; far half stays an aimless
shamble.
- Multi-ball / rapid fire: splatter is now a shooter — every tap/flick
fires immediately (dropped the toss ritual there), and serving while a
ball still flies stashes the old one into a new extraBalls array so it
keeps arcing and killing (cap 6). Refactored the kill into a shared
killZombie() with no ball coupling, used by ball hits, pellets, melee,
and extra balls.
- Machine-gun mode clarity: confirmed free-walk (drag/arrows move you,
auto-assist off) and tap-doesn't-serve during a horde; added a
code-drawn "rambo" racket held forward with a muzzle flash over the
player, and a splatter-specific serve prompt.
REVIEW on your phone — two opinionated calls, both easy to revert:
1. Dropped the toss in splatter (tap = instant quick-serve, pow 0.62).
Rapid fire, but no apex-timing quality/pierce. Want the toss back as
an option?
2. MG posture is a code-drawn forward racket, not a real body sprite —
good enough, or worth a proper p_mg sprite later?
Also: each rapid serve still auto-consumes a stocked bomb, so bombs
deplete fast now — flag if that feels wrong.
Verified via window.T: melee kills a 1.0m zombie and spares a 4.5m one;
a near-half zombie drifts x 3→1.9 toward you; firing twice leaves 1
stashed ball + a fresh serve (barrage screenshot); extra balls kill and
pierce; free-walk during a horde (x 0→2.7); horde-tap melees without
serving; tennis toss-serve and Phase-4 bomb consume still work; no
console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Winning your 2nd splatter game (G.splatGames) — or triple-tapping the
umpire in splatter (forceZombies now calls startHorde) — launches a 12s
horde (TUNE.hordeLen). During a horde: the match ball is gone and taps do
nothing; the racket auto-fires pellets straight up-court at TUNE.mgRate
(6/s, ±4° spread, 26 m/s, flat, 1.2s life) and the thumb DRAG steers you
(auto-assist disabled). Zombies pour in at TUNE.hordeRate (2.5/s) from the
far baseline and the sides, ignoring zMax; the speed ramp still applies.
Pellets live in a new zombies.js `pellets` array, kill on contact (always
splatter-quality). splatter() gains a fanfare flag — pellet kills make
gore/piles/points but skip the multi-kill streak so a horde doesn't spam
MASSACRE. splatPoint() gains a quiet flag: during a horde the umpire only
calls a score every >2s (game-win lines always speak); the HUD score keeps
ticking. Horde ends → setupPoint() resumes serving, voice('quiet_dark');
leftover zombies stay for you to mop up. Eaten stays lethal during hordes
(a zombie reaching you ends it and clears the swarm). Pellets render as
2×2 yellow tracers with a ground shadow; serve prompt suppressed while
G.horde. window.T exposes pellets + forceZombies.
NOTE for Oliver: per spec every game won after the 2nd triggers a horde,
and games won by the machine gun mid-horde count too, so play gets very
horde-heavy after game 2 — flag if you want a cooldown or a knob.
Verified via window.T: cheat + 2nd-game both launch the horde (1st does
not); ~29 spawns over exactly 12s; pellets stream (7 in flight) and clear
a lane, building piles/gore; 4 points scored but the umpire speaks once
(rate-limited); horde ends cleanly back to pretoss; eaten still fires
mid-horde; regression ladder green — tennis 11/12, Phase 1 flick-serve,
Phase 2 DOUBLE→TRIPLE, Phase 4 MASSACRE ×4; no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Ball boys deliver a bomb ball every TUNE.bombEvery (8) splatter kills, up
to TUNE.bombMax (3) in stock (G.bombs / G.killMeter in state). The next
serve auto-consumes one (hitServe, splatter-only) — no extra input, keeping
one-handed play. A bomb detonates on first zombie contact (regardless of
pace) or, if it misses everyone, on its first bounce: explode() splatters
everything within TUNE.bombRadius (2.5m), each kill feeding ball.kills so
the Phase-2 fanfare escalates naturally, and leaves a crater — big stain,
size-3 pile, 40 particles, 0.1s hitstop, boom(). New synth boom() in
audio.js. Bomb ball renders black with a flickering orange fuse; the HUD
shows stocked bombs as black/orange pips by the YOU line. Both explode
sites set phase='over' so the serve loop doesn't stall on the killed ball.
Alternative delivery ideas Oliver floated but not built: umpire throws it,
or court pickup.
Verified via window.T: 8th kill earns a bomb (meter resets); a serve
consumes one and renders #111 black + orange fuse; a pow-0 bomb amid 4
clustered zombies kills all 4 with 'MASSACRE ×4', boom, hitstop 0.1,
crater stain (r1.4) + size-4 pile; a bomb that misses still craters on
first bounce; bombs never leak into tennis (mode guard); 3 HUD pips; no
console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Kills now grow 3D-ish gore mounds, not just flat stains. zombies.js gains
a piles array {x,z,size,seed}: a kill within 0.6m of a pile grows it
(size +1, cap 4), else starts a new one (cap 30, oldest shifts out).
Ball boys shave overlapping piles at size -= dt*0.25 — far slower than
stain mopping (dt*1.6) — so net growth wins over a long match. Splatter
particles bumped 14→24, ~1/3 dark and longer-lived (settling gore),
render reads pt.dark for colour.
render.js draws each pile as seeded pixel-art blobs (mulberry32 from
p.seed): N=6+size*5 blobs, offset within size*0.28m, lifted up to
size*0.14m so the pile has visible height, weighted gore colours + ~10%
bone flecks. Blobs are built once and rebuilt only when the pile GROWS
(builtSize guard) — never on the per-frame mop-shrink — and each pile
costs a single proj() call (blob screen positions offset from the base).
Piles draw split far/near of the net like zombies so height occludes
right. window.T exposes render/piles/gore/parts for verification.
Verified via window.T: clustered kills build tall dense mounds while
singles stay small (screenshot), avg render 0.61ms with 10 piles, 0 blob
rebuilds across 120 frames, mop shrinks a size-4 pile at exactly 0.25/s,
no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
A single shot that splatters ≥2 zombies now escalates: DOUBLE KILL /
TRIPLE KILL / MASSACRE ×N flash, louder crowd, and a new umpire line
(double_kill / triple_kill / unbelievable m4a, recorded say -v Daniel).
ball.kills tracks the streak, reset on every fresh shot (doHit + hitServe).
zombies.js imports cheer (now exported from gameplay). The splatter pace
cut is now TUNE.zPierce (0.75, was hardcoded 0.5) so a hot ball plows
through a lined-up lane instead of stalling on the first kill.
Verified via window.T: a low ball down a one-side lane kills 3→TRIPLE and
5→MASSACRE ×5 with escalating flash, streak resets on the next serve, the
three new lines serve 200 and match the existing m4a format, no crash when
the ball dies mid-streak, no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Input during the 'over' beat is no longer swallowed: a tap/flick while
G.phase==='over' (splatter only) resets inline and falls through to the
serve logic, so the finger is the only cadence limit. Spent balls
(lastHit 'X' after a stagger bounce) and hopeless balls (out of the
z/x bounds) are retired immediately instead of lingering until they roll
out. New TUNE.splatterOverT (0.1) replaces the hardcoded 0.25 over-timer.
The out-of-bounds z-bounds gate on travel direction so a quick-serve born
behind the baseline (P.z up to 26, heading vz<0 to the far court) isn't
killed on frame one.
Verified via window.T: flick/tap during 'over' serves same frame; spent
ball dies the frame it bounces; serve->serve latency 0 frames with
immediate flicks; tennis 'over' unchanged (2.2s pause, tap ignored);
tennis CPU still returns 11/12 serves; no console errors.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Five phases, each independently shippable with verify recipes: tighter
shooting loop, multi-kill umpire fanfare, procedural gore piles, bomb
balls delivered by ball boys, horde waves with machine-gun racket.
Racket zombies deferred to a design checkpoint (Phase 6, not first cut).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Field data (miss log) showed the dominant unfair miss: the assist parks
you on the landing spot, the ball spends the whole swing window below
minY rising off the bounce at your feet, and becomes hittable one frame
after the window closes. Root fix: the below-ankles rejection now only
applies to a DROPPING ball — rising post-bounce balls can be scooped at
any height (a half-volley). Feet-bounce taps go from ~0 to 19/30 winning
frames; 30 simulated real points now log 50 hits, 0 whiffs.
Also: swing-log snapshots record the same swing-timer value trySwing
tests (removes the one-frame misclassification behind 'unclassified'),
and tapping the scoreboard toggles an on-screen dump of the last 9 log
entries so live situations can be screenshotted from the phone.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Whiffed swings sample the ball's approach each frame and classify the
miss at swing expiry: tap too early (with ms), tap too late, ball line
wide, too high/low, out of reach. Balls that die on your side without
a swing log as PASSED with closest-approach data. Ring buffer of 50 at
T.G.missLog; the latest miss reason flashes on the HUD for 3.5s
(TUNE.missHud to disable). CPU serve-return benchmark still 11/12.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
splatT now ticks while in splatter mode and scales spawn speed by
1 + min(1.5, splatT/70). A zombie within 0.7m of the player ends the
run: gore burst, 'game, set, massacre', dark EATEN. overlay with final
games and a tap-to-restart (gated 0.7s so death-spam doesn't skip it).
Zombies keep shambling on the end screen but no longer score. Also
verified the two prior unverified items: quick-serve cadence (0.25s
between balls, flick = instant aimed serve) and flick aiming across
the net (far/near lane selection works as designed). HANDOFF updated.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
A ball passing pre-bounce moves at full pace with no bounce cue to time
against, so marker-behind volleys needed frame-tight taps. Pre-bounce
player contact now widens reach x1.4 and the swing window x1.8 (VOLLEY
in config.js). Also clear G.wasServe in doHit so a serve returned out
of the air doesn't fault-check the return, and launch.json uses
autoPort.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Done (unverified): faster serve cadence in splatter (overT 0.25, serve from
where you stand, flick = instant aimed quick serve), aim-anywhere targeting
relative to the player. Not done: zombie speed ramp (G.splatT exists but is
never incremented), eaten-on-touch death + restart screen. Full state and
plans in HANDOFF.md.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- doHit/hitServe in splatter mode lock onto zombies instead of tennis court
depths: your flick picks the lane and depth band, the shot targets the best
match anywhere on the court (including your own side) with a walking lead;
serves auto-track the most advanced shambler
- hidden shortcut: tap/click the umpire three times within 1.6s during tennis
mode to summon the transition immediately
Verified: near-side and far zombies killable, cheat triggers transition,
tennis mode targeting untouched.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Win your first game and the applause cuts off mid-clap. The palette drains,
the umpire lowers his voice ('Quiet... please'), your opponent turns — torn
red polo, dragging his racket — and shamblers come over the billboard wall.
The scoreboard rewrites CPU to THEM. 'Play.'
- zombies.js: shamblers walk your way; quality shots splatter them (gore
decal + particle burst + wet synth splat), weak sitters only stagger them
back; one crossing your baseline is a point for THEM
- tennis scoring machinery keeps running untouched: fifteen, thirty, deuce,
and 'Game, set... massacre' on a game win, all in recorded umpire English
- ball boys mop the gore they pass (their destiny fulfilled)
- transition: palette lerp, scripted spawns incl. the turned opponent,
new recorded lines (quiet_dark, remain_seated, play, new_balls)
- moan ambience, drained splatter palette, all zombie params in TUNE
Verified: transition triggers on first game win, splat/stagger/baseline
scoring all correct, dead-ball flow feeds fresh serves, tennis mode
regression clean (6/6 returns, 6/6 points resolved).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
game.js (830 lines) -> 9 modules, native ES modules so still zero build step:
dom canvas handles (imports nothing; keeps cycles harmless)
config TUNE (live-tunable) + structural constants
state all mutable game state (G) + setupPoint/sendBoy
audio sfx synthesis, recorded umpire voice, reverb, speech fallback
input keyboard + touch, exports axes and takeFlickAim()
gameplay ballistics, swings, serve, rules, AI, update loop
render camera, viewport, sprites, crowd, all drawing
panel T tuning UI
main boot, loop, intro, window.T test hooks
Deduped into named constants: bounce tempo (was in 3 places), contact
height band, intercept zone depth, home positions, player bounds, toss
params, shot depths, pose hold time, sprite scale, actor heights. Also
extracted drawShadow/drawBall/expirePose from repeated code.
One intentional import cycle (input <-> gameplay), safe: both sides only
call functions at runtime, never during module evaluation.
Regression-verified in browser sims: point cycle, CPU returns 11/12,
assist contract 8/8, corner-winner gradient intact (0/12 perfect corners
returned, 10/12 center balls returned).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
predictLanding stepped the trajectory in 10ms chunks and returned the first
point past ground level — an overshoot of up to ~25cm that varied per frame,
which is what actually jittered (the earlier pixel-snap only addressed
sub-pixel shimmer). The landing point of a parabola has an exact solution;
computing it directly makes the prediction identical every frame.
Measured: max frame-to-frame movement 5.5mm, was ~25cm.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Hand-raised frame while the ball rises, pat-down frame from the apex on —
synced to the ball's direction instead of a height threshold. Includes
Oliver's hand-tuned ball offset.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- p_bounce/p_bounce2 re-extracted from Oliver's corrected _sheet_pbounce.png
(racket properly in the right hand)
- bounce ball offset 0.4 -> 0.32 so it sits under the reaching hand
- landing rings draw with integer-snapped center/radii and a solid 2px
stroke — the sub-pixel anti-aliasing shimmer read as flickering
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The sprite file was fine — drawChar mirrors sprites by P.facing, which
persisted from the last run direction, so the pre-serve bounce stance
randomly flipped (racket in the wrong hand, ball beside the wrong hand).
setupPoint now resets both players to the canonical righty stance.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- boy runs on a proper 4-phase cycle (stride, pass, mirrored stride, pass)
- server holds the crouched bounce stance through pretoss instead of
flickering to standing idle; hand-down/hand-up frames sync with the ball,
which now bounces floor-to-hand height
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- fake topspin: quality shots dive under extra effective gravity, so real pace
(up to 28 m/s) can clear the net AND land in — without it the net-clearance
loop silently slowed every shot to a coverable lob, which is why the CPU
returned everything regardless of aim
- no grass-scraping: balls below ankle height (0.24m) are past you, both sides
- CPU: 0.45s shot-read delay, 4.3 m/s legs, half-speed recovery between shots.
Verified gradient: perfect/good corner shots are winners, center balls and
weak shots still come back
- player aimed shots go wider (3.3m vs 2.7m)
- ball boy: nano-banana mirrored stride frames (was stride-vs-hop), height
1.2m, z-ordered against umpire and CPU (no more running over the chair)
- umpire voice through a synthesized convolver reverb — center-court PA echo
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- intercept() now picks a point the runner can actually reach in time
(travel-time feasibility), falling back to the deepest hittable point
- tapping no longer slows the auto-run: anticipating a shot doesn't lose it
- assist legs slightly superhuman (1.15x) so positioning is guaranteed
- ball boy run frames regenerated with contrasting stride/gather poses
(previous pair was near-identical, which read as no animation)
Verified: 10/10 CPU shots end inside the honest 1.3m contact radius with
zero manual movement.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- ball boy redesign: spawns at the sideline on point end, sprints across at
the ball's depth with a proper side-view run animation, scoops the ball
mid-run, despawns off the other side (no more net-post idling/sliding)
- hit feel: ball snaps to the racket at the contact frame so hits visually
connect; contact radius tightened 1.7 -> 1.3 (assist does the positioning,
the tap must be honest); missed swings now play an audible swish
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- white ring shows where the incoming ball will land; yellow/red ring shows
where your shot will land (red = going out) — Mario-Tennis-style feedback
- ball boys wait at the net posts, fetch every dead ball, and trot home
- canvas renders at 2x density, all sprites re-sliced at 112px; run/swing
sheets regenerated in the finer style
- assist: 0.35m deadzone + facing hysteresis kills the left/right flicker;
player reach 1.5 -> 1.7
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- 23 pre-recorded umpire lines (macOS say, en-GB Daniel) played via WebAudio,
works on mobile; speechSynthesis stays as fallback only
- umpire chair + two ball boys (generated sprites) dress the court
- court redrawn: doubles alleys, white perimeter border, clearly darker out area
- intro overlay with control symbols; first tap dismisses it and unlocks audio
- nginx now serves everything Cache-Control: no-cache so a reload always
revalidates and picks up new deploys
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Same predictive brain as the CPU: simulate the trajectory, run to where the
ball will be hittable (x and z), and drift back to home position after your
own shot. Full speed while chasing, 55% while recovering.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- new 5-pose sheets per character: idle weight-shift x2, ball-bounce crouch,
serve trophy pose (toss), overhead smash
- serve shows toss stance through the ball toss, smash frame on contact
- auto-assist: full player speed, adds depth tracking after the bounce,
and drives the run animation + facing like manual movement
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- doHit now trades pace for loft when contact is low, margin scales with
shot quality; AI prefers waist-high interception instead of ankle-height
- serve stance held through toss, run cycle with bob, receiver split-step,
server bounces the ball while waiting
- speechSynthesis unlocked inside first touch gesture for iOS
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The AI armed its swing at aiReach+0.4 but contact required aiReach, so it
always swung one guaranteed-whiff too early and the 0.4s cooldown consumed
the whole approach window. Also: predictive interception instead of ball-chasing,
shorter whiff recovery, slightly faster legs.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>