# Vibegame

A 2D multiplayer platformer inspired by Ultimate Chicken Horse: players take turns placing
blocks and traps, then race each other through the course they just sabotaged.

## Stack

- **Monorepo**: pnpm workspaces + Turborepo
- **Client**: Next.js (App Router) + React + Tailwind CSS + shadcn/ui, PixiJS v8 renderer
- **Server**: Node.js + `ws`, authoritative simulation at 60 Hz
- **Simulation**: custom deterministic 2D physics shared between client and server (`packages/shared`)
- **Persistence**: repository interfaces with in-memory implementations (Prisma/MySQL prepared, not wired)
- **Testing**: Vitest

## Getting started

```bash
pnpm install
pnpm dev        # starts the Next.js app (http://localhost:3200) and the game server (ws://localhost:3001)
pnpm test       # unit + integration tests
pnpm build      # production build of all workspaces
```

## Repository layout

```
apps/web         Next.js client — menus, HUD, Pixi canvas
apps/server      Authoritative game server (WebSocket)
packages/shared  Deterministic simulation core, physics, protocol, game modes, maps
packages/db      Persistence interfaces + in-memory implementations + Prisma schema stub
docs/            Architecture, roadmap, decision records
```

See [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) for the full picture and
[docs/ROADMAP.md](docs/ROADMAP.md) for what works today vs. what is planned.
