A multiplayer 8-bit style racing game where players tap to run! Supports 2-50 concurrent players with dynamic scaling.
- Multiplayer Racing - Up to 50 players in a single race
- Color + Pattern System - Unique visual identification for all players
- Dynamic Scaling - Sprites automatically resize based on player count
- Mobile Controls - Tap anywhere on phone screen to run
- Host Controls - Adjustable race length and medal count
- NES-Style Graphics - Colorful 8-bit aesthetic
- QR Code Joining - Easy mobile access
npm install
npm startThe server will display:
- Main Display URL: Open on TV/computer
- Local Network URL: Share with phones on same WiFi
# Install ngrok globally (one time)
npm install -g ngrok
# Run with ngrok tunnel
npx ngrok http 3000Copy the HTTPS URL (like https://abc123.ngrok.io) and update your .env:
BASE_URL=https://abc123.ngrok.io
Then run:
npm startnpm run start:tunnelThis creates a public URL like https://retro100m.loca.lt
- Forward port 3000 on your router
- Find your public IP: https://whatismyip.com
- Update
.env:
BASE_URL=http://YOUR_PUBLIC_IP:3000
- Host opens main display (http://localhost:3000)
- Players scan QR code or enter room URL
- Players choose color and enter name
- Host starts race when ready (min 2 players)
- TAP FAST to run!
- Top finishers get medals 🥇🥈🥉
# For local network
# Leave empty - will auto-detect
# For public access
BASE_URL=https://your-domain.com
# Server port
PORT=3000- Race Length: 60m Sprint / 100m Classic / 200m Endurance
- Medal Count: Top 3 / Top 5 / Top 10
| Players | Sprite Size | View Mode | Special Features |
|---|---|---|---|
| 2-12 | 32px | Full view | Names visible |
| 13-20 | 24px | 2 lanes | Minimap enabled |
| 21-35 | 16px | 3 lanes | Focus view + minimap |
| 36-50 | 12px | 4 lanes | Minimap only |
# Create Heroku app
heroku create your-app-name
# Deploy
git push heroku main
# Set environment variable
heroku config:set BASE_URL=https://your-app-name.herokuapp.com- Connect GitHub repo
- Set environment variables in dashboard
- Deploy automatically on push
# Install Node.js and npm
curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -
sudo apt-get install -y nodejs
# Clone and install
git clone https://github.com/yourusername/retro-100m.git
cd retro-100m
npm install
# Use PM2 for production
npm install -g pm2
pm2 start server/index.js --name retro-100m
pm2 save
pm2 startup
# Setup nginx reverse proxy (optional)
sudo apt-get install nginx
# Configure nginx to proxy port 3000# Run with auto-restart on changes
npm run dev
# Test with specific number of mock players
# (Add test script in future update)- Backend: Node.js, Express, Socket.io
- Frontend: HTML5 Canvas, Vanilla JS
- Real-time: WebSockets
- Graphics: Canvas API with pixel art styling
- Ensure phone and server are on same WiFi network
- Check firewall isn't blocking port 3000
- Try using ngrok for remote testing
- Update
BASE_URLin.envfile - Restart server after changing environment variables
- Ensure good WiFi connection
- Consider reducing race length for 40+ players
- Host on stronger network/server
MIT