Prumble Rompt is a browser office-brawl game built with Phaser 4, TypeScript, Vite, Node, and WebSockets. Four fighters battle through a three-round series with improvised weapons, arena changes, prompt-driven behavior, AI-generated fight reactions, and one shared multiplayer lobby.
Spec status: the game is deployed and playable, includes progression through rounds and a parking-lot bonus arena, documents the architecture and build path, and runs a single server-authoritative lobby. See Spec Compliance.
- Render: https://rumble-prompt.onrender.com/
- Local-only mock agent mode: http://127.0.0.1:5173?agent=mock
The production Render service is a Node web service. It serves the Vite build and owns the single WebSocket lobby. If no GEMINI_API_KEY is configured, server-side prompt handling falls back to the mock provider.
Requirements:
- Node.js 20+; this repo has been tested with Node 24
- pnpm 9+
- Optional Gemini API key for live agent responses
pnpm install
pnpm devOpen http://127.0.0.1:5173 for local single-browser play. Add ?local to force local mode when running through the Node server.
For a local multiplayer smoke test:
pnpm build
PORT=3000 pnpm startOpen http://127.0.0.1:3000 in multiple tabs.
For live Gemini-backed prompts, set GEMINI_API_KEY in the shell or deployment environment. GEMINI_MODEL defaults to gemini-2.5-flash-lite. Set AGENT_PROVIDER=mock to force mock prompt responses.
pnpm build
pnpm previewpnpm build runs client and server type checks, emits the browser build to dist/, and emits the Node server bundle to dist-server/. pnpm preview serves only the static browser build at http://127.0.0.1:4173; use pnpm start for multiplayer.
- Four fighters: red, blue, green, and gold, with fixed office-worker names so every viewer in the shared room sees the same cast.
- Three-round series through the office, bathroom, and parking lot bonus arena.
- Progression comes from the round series, crown counts, faster late-round movement, fatigue pressure, room-specific breakables, and escalating arena items.
- In multiplayer, every connected visitor joins the single queue. Any queued player can start a fight; the first four queued humans fight and the rest watch.
- Players are connected humans assigned fighter seats. Empty fighter seats are bots. Bots never call an LLM.
- Lobbyists are generic sidelined crowd placeholders for overflow connected clients. They are visual only, never fighters, and never use prompts or actions.
- Active human fighters are hidden from their players. A player influences their hidden assigned fighter by typing natural-language shouts during the fight.
- Spectators cannot affect the fight.
- A shout is interpreted into a literal action plan: up to five
move,pickup,attack,retreat, orwaitsteps, plus emergency interrupts (stop, run away, drop it) and a clear-memory intent (forget that). When a shout names a signature move (fastball, ground and pound, body slam, an item smash), a finisher compiler back-solves the setup chain so the move actually lands. Soft pressure (attention words, mood, confidence, duration) remains as a secondary lane that biases target, object, movement, and posture probabilistically. - Pickups include cups, chairs, computers, fire extinguishers, traffic cones, stop signs, bicycles, and a saguaro cactus, plus a hidden one-use move where a fighter rips a health bar off the HUD.
- Window throws, re-entry, object collisions, crowding, recovery, stun, music, and sound effects are handled by the simulation and render layers.
- Parking-lot rounds spawn falling NPCs who crash through offscreen glass, get stunned, may grab a loose pickup, and wander off.
- HR color commentary: each round closes with a dry one-line incident report, and the series ends with an HR "closing determination" dossier. Other players' shouts surface as floating room-shout text for everyone except the sender.
- Spec Compliance
- Architecture
- Setup and Deployment
- Technical Decisions
- AI Learning Log
- Demo Walkthrough
- Source specs: docs/specs
src/
main.ts Browser DOM shell and Phaser bootstrap
agent.ts Gemini/mock agent provider client
agentContract.ts Agent response schema (pressure + command plan) and normalization
agentPrompt.ts Shared player-agent system instruction
agentFallback.ts Mock/offline prompt-to-moment interpreter
incidentReport.ts Round incident-report prompt, template, and normalization
seriesDossier.ts Series HR-closing prompt, templates, and normalization
fightScreenDossier.ts Fight-screen incident dossier presentation helper
roundLog.ts Dev transcript logging client
audio/ Shared music catalog and audio preferences
arenas/ Phaser-free layout registry, content, and pickup catalog
multiplayer/
client.ts Browser WebSocket client and ClientMode
protocol.ts Shared lobby/snapshot/message types
scenes/
BrawlScene.ts Main Phaser scene, rendering, sounds, prompt events
presentationHandlers.ts Exhaustive presentation-event dispatch
arenas/ Phaser views for pickups, windows, breakables, lobbyists
art/ Runtime texture generation
audio/ Scene audio playback and synchronization
effects/ Particles, window cracks, and floating room shouts
fighters/ Fighter sprite rendering and waiting-fighter visuals
hud/ Fight HUD and incident-report slip
game/
simulation.ts Public barrel for simulation types and BrawlSimulation
simulation/ Fight state machine, rounds, AI, command plans, finishers, falling NPCs, round digest
rounds/ Active round-to-arena sequence
moves.ts Move catalog and fighter ids
Fighter.ts Fighter state, health, held items, cooldowns
fighterNames.ts Deterministic fighter name roster
healthBars.ts Health-bar grab constants and helpers
assets/ Title art, music, and sound effects
docs/ Specs and required project documentation
scripts/
dev.sh Local dev server helper
push-all.sh Push current branch to both configured remotes
server/
index.ts Single-lobby Node/WebSocket server
agent.ts Server-side Gemini/mock prompt provider
incidentReport.ts Server-side incident-report generation
seriesDossier.ts Server-side series-closing dossier generation
roundLog.ts Server-side round-log buffer and query
| Host | Link |
|---|---|
| GitHub | https://github.com/MichaelHabermas/prumble-rompt |
| GitLab (Gauntlet) | https://labs.gauntletai.com/michaelhabermas/prumble-rompt |
Both remotes are configured in this repo as github and gitlab. To push the current branch to both:
scripts/push-all.shAdd --tags to push tags as well.