Multiplayer classic board games, real-time. Built for friends.
PlayGrid is a multiplayer board game platform where players create lobbies, challenge friends, and play classic games in real-time. Built with TypeScript, Colyseus (real-time server), and PixiJS (game rendering), it's designed to be fast, responsive, and fun.
PlayGrid currently features:
- Checkers — Classic two-player checkers with smooth piece movement
- Risk — Territory control strategy game for multiple players
More games coming soon, including Backgammon!
- ⚡ Real-time multiplayer using WebSockets (Colyseus)
- 🎨 Smooth game rendering with PixiJS and HTML5 Canvas
- 🎯 Web-based lobby for discovering and joining games
- 🏗️ Plugin-based game architecture — easy to add new games
- 🧪 Fully tested with Vitest (unit) and Playwright (E2E)
| Layer | Technology |
|---|---|
| Client | TypeScript, PixiJS v8, Vite, React |
| Server | TypeScript, Colyseus, Node.js, Express |
| Shared | TypeScript schemas and game constants |
| Infrastructure | Docker, Azure Container Apps, PostgreSQL |
| Testing | Vitest (unit), Playwright (E2E) |
- Node.js 22+ (with npm)
- Docker Desktop or Docker Engine + Compose plugin (recommended for local PostgreSQL)
- Git
-
Clone and install:
git clone https://github.com/dkirby-ms/playgrid.git cd playgrid npm ci -
Create your local env file:
cp .env.example .env
-
Start PostgreSQL for local development:
docker compose up -d postgres # or: npm run db:upThis starts a local PostgreSQL 15 instance on
localhost:5432with databaseplaygridand persists data in thepostgres-dataDocker volume. The server will run its migrations on startup. -
Start the dev environment:
npm run dev
This runs both the client (PixiJS at
http://localhost:5173) and server (Colyseus athttp://localhost:2567/ws://localhost:2567) concurrently. -
Verify it's working:
- Open
http://localhost:5173in your browser - Create a lobby and invite a friend (or open another browser tab)
- Play!
- Open
- Connection string:
postgresql://postgres:postgres@localhost:5432/playgrid - Start DB:
docker compose up -d postgres - Stop DB:
docker compose down - Follow logs:
docker compose logs -f postgres - Reset DB volume (destructive):
docker compose down -v
playgrid/
├── client/ # PixiJS game client (Vite)
│ ├── src/
│ │ ├── components/ # Game rendering components
│ │ ├── pages/ # Lobby, game, and settings pages
│ │ └── game/ # Game-specific logic
│ └── dist/ # Built output
├── server/ # Colyseus multiplayer server
│ ├── src/
│ │ ├── rooms/ # Game room types (Chess, Checkers, etc.)
│ │ ├── database/ # PostgreSQL connection and queries
│ │ └── index.ts # Server entry point
│ └── dist/ # Built output
├── shared/ # Shared TypeScript types
│ └── src/
│ ├── types/ # Game and room interfaces
│ ├── constants/ # Game rules and configuration
│ └── utils/ # Shared utility functions
├── e2e/ # Playwright end-to-end tests
├── docs/ # Architecture and design guides
├── .squad/ # Team docs and decisions
└── package.json # Monorepo workspace configuration
Games in PlayGrid follow a plugin architecture. Each game implements the IGamePlugin interface:
interface IGamePlugin {
name: string; // "Chess", "Checkers", etc.
rules: GameRules; // Move validation, board state
stateShape: Schema; // Serializable game state
onMessage(action: string, payload: unknown): void;
}Adding a new game:
- Create a room class in
server/src/rooms/(e.g.,ConnectFourRoom.ts) - Implement
IGamePluginwith your game rules and state - Register it in the server's room dispatcher
- Add client-side rendering in
client/src/game/ - Write E2E tests in
e2e/
See docs/game-systems-design.md for the complete plugin pattern spec.
npm run test # Unit and integration tests (Vitest)
npm run test:watch # Watch mode for development
npm run test:e2e # End-to-end tests (Playwright)npm run build # Build all workspaces
npm run lint # Lint TypeScript and JavaScriptPlayGrid is built for cloud deployment on Node.js with PostgreSQL. The server and client are independent:
- Client: Static HTML/JS/CSS bundle, served by any CDN or static host
- Server: Node.js Express + Colyseus, with PostgreSQL for persistence
See docs/ for deployment architecture and environment configuration.
We welcome contributions! Please read CONTRIBUTING.md for guidelines on:
- Setting up your development environment
- Branch strategy and workflow
- Code style and testing practices
- How to submit issues and pull requests
For a deep dive into the architecture, see docs/architecture.md.
This project is developed by a team of specialists working together:
| Name | Role | Status |
|---|---|---|
| Hal | Lead | ✅ Active |
| Gately | Game Dev (Rendering) | ✅ Active |
| Pemulis | Systems Dev (Backend) | ✅ Active |
| Steeply | Tester | ✅ Active |
| Marathe | DevOps / CI-CD | ✅ Active |
| Joelle | Community / DevRel | ✅ Active |
| Mario | UX Consultant | ✅ Active |
| Scribe | Session Logger | 📋 Silent |
| Ralph | Work Monitor | 🔄 Monitor |
| Copilot | Coding Agent | 🤖 Autonomous |
Plus: GitHub Copilot helping us code faster and smarter.
For detailed team info, see .squad/team.md.