towerdef/public
Claude 2098d59c1f Versus mode: attack vs defend (sim, bots, server, client)
One player defends, the other plays the Internet: earns credits over time and
spends them on packets, upgrades and sabotage. Two rounds with swapped roles,
timed (the faster fall wins). Built end to end, NOT yet QA'd or balanced.

Sim (public/js/sim.js, TD.VS table): attacker economy (income, lifetime bonus,
leak payback), spawn / stage / launch convoys, 7 tech tracks, abilities (EMP,
decoy, surge, DDoS), defender tools (scan, patch, repair, quarantine), role-checked
commands, round result, role-private state. Co-op/solo unchanged (24 scripted
games replay identically).

Bots (public/js/bot.js, tools/versus.js): defender (maze + turrets) and attacker
(budgeted spender reading the tower mix); headless bot-vs-bot runner.

Server (server/versus.js, protocol doc): versus rooms with lobby / countdown /
playing / roundover / matchover, role stamping, cross-role refusal, role-private
priv messages at 4 Hz, computer seat, freeze/forfeit rules, no pause/speed.

Client (public/js/versus.js): setup dialog (role, length, vs computer or online),
countdown, defender tools row, attacker unit shop with convoy + launch, tech and
abilities, gateway choice, round/match screens, sounds, phone-first dock rows.

Status and next steps (balance: the attacker currently wins ~100% of bot rounds;
QA with two browsers; layout matrix rerun) are in docs/NEXT.md and docs/VERSUS.md.
The full planned workflow incl. balance/QA prompts is in docs/workflows/versus-full.js.

253 unit tests pass; one smoke e2e run; no other e2e per the user's request.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Tb8pW2KAN4oFkh1aK1BfD8
2026-10-11 10:22:29 +00:00
..
assets/music Co-op robustness, audio/a11y, new towers and enemies, Uplink rebalance 2026-10-10 21:18:43 +00:00
css Versus mode: attack vs defend (sim, bots, server, client) 2026-10-11 10:22:29 +00:00
icons Add co-op server, deploy docs, e2e suite and wire in the music tracks 2026-10-09 19:57:27 +00:00
js Versus mode: attack vs defend (sim, bots, server, client) 2026-10-11 10:22:29 +00:00
index.html Versus mode: attack vs defend (sim, bots, server, client) 2026-10-11 10:22:29 +00:00
manifest.webmanifest Add Netwall solo client, shared simulation core and protocol spec 2026-10-09 19:14:35 +00:00
sw.js Versus mode: attack vs defend (sim, bots, server, client) 2026-10-11 10:22:29 +00:00