A real-time multiplayer dartboard game built with React, Node.js, Express, and WebSocket. This app allows players to compete in classic X01 dart games (e.g., 501, 301, 101) with real-time updates and automatic scoring.
- Real-Time Multiplayer: Play with friends in real-time using WebSocket.
- Interactive Dartboard: Clickable dartboard with accurate scoring.
- Game Modes: Choose between 501, 301, or 101 starting scores.
- Checkout Rules: Supports both single and double checkout rules.
- Game Lobby: Create or join game rooms with up to 8 players.
- Throw History: Track all throws, including valid and invalid ones.
- Winner Detection: Automatically determines the winner based on the game rules.
git clone https://github.com/stefanrudi/darts-counter.git
cd darts-counterNavigate to the server and client directories and install the required dependencies:
cd server
npm installcd ../client
npm installRun the server from the server directory:
npm run devThe server will start on http://localhost:3001.
Run the client from the client directory:
npm run devThe client will start on http://localhost:5174.
- Enter Your Name: Start by entering your username.
- Create or Join a Game:
- Create a new game room with your preferred settings (e.g., starting score, checkout type, max players).
- Or join an existing game room from the list of available games.
- Play the Game:
- Take turns throwing darts by clicking on the interactive dartboard.
- The app automatically calculates scores and tracks throw history.
- Win the Game:
- The winner is determined automatically based on the game rules (e.g., double checkout for 501).
dartboard-game/
├── client/ # React Frontend
└── server/ # Server (Express & WebSocket)
- Node.js: v16 or higher
- npm: v8 or higher
Enjoy playing darts with your friends! 🎯