Thomas's Portfolio

Werewolf Game - Multiplayer Party Game Platform

September 12, 2025 (2mo ago)

🐺 Werewolf Game - Multiplayer Party Game Platform

A fully automated, no-moderator Werewolf game built with React, NestJS, and Socket.io. Designed for friends sitting together in a circle — just one device acts as the game master, announcing roles and running night/day cycles.

Werewolf Game Banner
Werewolf Game Banner

🎯 Project Overview

This project brings the traditional Ma Sói party game into a digital-first, seamless experience. No need for a human moderator — the platform handles:

  • Role assignment
  • Night phase orchestration
  • Voting & elimination
  • Game end conditions and announcements

🏗️ Architecture Highlights

  • Real-time Gameplay: Socket.io for instant state synchronization across all devices
  • Modular Game Engine: Supports adding custom roles and rules easily
  • Cross-Platform: Works on mobile, tablet, or desktop browsers
  • Offline First: Can run on local network without internet access
  • Extensible Backend: Built on NestJS for scalability and maintainability

🎨 Design Philosophy

The goal was to make the experience natural and immersive, just like the classic tabletop game:

  • Voice Narration: Game master narrates the night/day phases using text-to-speech
  • Minimal UI: Focus on the players, not the screen
  • Clear Feedback: Vibrations, sound effects, and animations to indicate phases
  • Role Privacy: Each player privately sees their role on their own device

✨ Core Features

🎮 Gameplay Features

  • Role Management: Supports Werewolf, Villager, Seer, Doctor, and custom roles
  • Automated Game Flow: No need for a moderator
  • Dynamic Narration: Announces events and deaths automatically
  • Voting System: Secure voting interface with countdown timer

📱 UX & Accessibility

  • Mobile-First UI: Designed for players sitting together using phones
  • Dark Mode: Immersive night-time experience
  • Offline Mode: Works without internet (LAN play)
  • Sound & Haptics: Enhance immersion during night/day cycles

🛠️ Developer Experience

  • TypeScript First: Strongly typed game logic and events
  • Modular Engine: Easily add new roles or modify rules
  • Testable Logic: Jest tests for core game mechanics
  • Easy Deployment: Dockerized backend + Vercel-ready frontend

🏗️ Technical Implementation

🔧 Technology Stack

// Core Technologies - React 18 (with Hooks) - NestJS (REST + WebSocket Gateway) - Socket.io (Real-time communication) - TypeScript (Strict mode) - Tailwind CSS (UI styling) // Tooling & Deployment - Docker (Containerization) - pnpm (Package management) - ESLint + Prettier (Code quality) - Jest (Unit tests) --- title: "Werewolf Game - Multiplayer Party Game Platform" category: Game Development startDate: 2025-03-01 endDate: 2025-09-01 publishedAt: 2025-09-12 summary: "An innovative, fully automated Werewolf (Ma Sói) game platform that removes the need for a human moderator. Players sit in a circle, connect to the game on one device, and experience a seamless, AI-powered game flow." tags: - React - NestJS - Socket.io - Multiplayer - Game Development - Real-time - UX banner: /images/banner/projects/werewolf-game.png alt: "Werewolf Game - AI-Powered Moderator for Party Games" --- # 🐺 Werewolf Game - Multiplayer Party Game Platform A fully automated, **no-moderator** Werewolf game built with **React**, **NestJS**, and **Socket.io**. Designed for friends sitting together in a circle — just one device acts as the game master, announcing roles and running night/day cycles. <div align="center"> <strong> <a href="https://github.com/hoatepdev/werewolf-server">💻 Source Code Server</a> &nbsp;&nbsp;&bull;&nbsp; <a href="https://github.com/hoatepdev/werewolf-client">💻 Source Code Client</a> &nbsp;&nbsp;&bull;&nbsp; <a href="https://werewolf-game.hoatepdev.com">🎮 Play Demo</a> </strong> </div> ![Werewolf Game Banner](/images/banner/projects/werewolf-game.png) ## 🎯 Project Overview This project brings the traditional **Ma Sói** party game into a **digital-first, seamless experience**. No need for a human moderator — the platform handles: - Role assignment - Night phase orchestration - Voting & elimination - Game end conditions and announcements ### 🏗️ Architecture Highlights - **Real-time Gameplay**: Socket.io for instant state synchronization across all devices - **Modular Game Engine**: Supports adding custom roles and rules easily - **Cross-Platform**: Works on mobile, tablet, or desktop browsers - **Offline First**: Can run on local network without internet access - **Extensible Backend**: Built on NestJS for scalability and maintainability ### 🎨 Design Philosophy The goal was to **make the experience natural and immersive**, just like the classic tabletop game: - **Voice Narration**: Game master narrates the night/day phases using text-to-speech - **Minimal UI**: Focus on the players, not the screen - **Clear Feedback**: Vibrations, sound effects, and animations to indicate phases - **Role Privacy**: Each player privately sees their role on their own device ## ✨ Core Features ### 🎮 Gameplay Features - **Role Management**: Supports Werewolf, Villager, Seer, Doctor, and custom roles - **Automated Game Flow**: No need for a moderator - **Dynamic Narration**: Announces events and deaths automatically - **Voting System**: Secure voting interface with countdown timer ### 📱 UX & Accessibility - **Mobile-First UI**: Designed for players sitting together using phones - **Dark Mode**: Immersive night-time experience - **Offline Mode**: Works without internet (LAN play) - **Sound & Haptics**: Enhance immersion during night/day cycles ### 🛠️ Developer Experience - **TypeScript First**: Strongly typed game logic and events - **Modular Engine**: Easily add new roles or modify rules - **Testable Logic**: Jest tests for core game mechanics - **Easy Deployment**: Dockerized backend + Vercel-ready frontend ## 🏗️ Technical Implementation ### 🔧 Technology Stack ```typescript // Core Technologies - React 18 (with Hooks) - NestJS (REST + WebSocket Gateway) - Socket.io (Real-time communication) - TypeScript (Strict mode) - Tailwind CSS (UI styling) // Tooling & Deployment - Docker (Containerization) - pnpm (Package management) - ESLint + Prettier (Code quality) - Jest (Unit tests)