Spaces:
Sleeping
Sleeping
File size: 2,576 Bytes
806f43a fbf0f7b 806f43a | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | ---
title: Drawable
sdk: docker
emoji: ๐
colorFrom: blue
colorTo: pink
---
# ๐จ Drawable
> The ultimate Draw & Guess game โ skribbl.io clone with superpowers.
## ๐ Features (beyond skribbl.io)
| Feature | Drawable | skribbl.io |
|---|---|---|
| Power-ups (Reveal, Time Warp, Bomb) | โ
| โ |
| Emoji reactions (floating) | โ
| โ |
| Drawing replay after each round | โ
| โ |
| Live score graph timeline | โ
| โ |
| Team mode (Red vs Blue) | โ
| โ |
| Sudden Death (wrong = lose points) | โ
| โ |
| Quick Draw mode (20s) | โ
| โ |
| 10 word categories | โ
| โ |
| Custom words | โ
| โ
|
| Achievements system | โ
| โ |
| Streak bonuses | โ
| โ |
| Host kick player | โ
| โ
|
| Spectator mode | โ
| โ |
| Undo stroke | โ
| โ |
| Shape tools (line, rect, circle) | โ
| โ |
| Bucket fill tool | โ
| โ
|
| Close-guess detection | โ
| โ |
## ๐ File Structure
```
drawable/
โโโ server.js # Node.js + Socket.IO backend
โโโ words.js # 300+ words across 10 categories
โโโ package.json
โโโ Dockerfile
โโโ .dockerignore
โโโ public/
โโโ index.html # Lobby
โโโ game.html # Game screen
โโโ css/style.css
โโโ js/
โโโ lobby.js
โโโ game.js
```
## ๐ Run Locally
```bash
npm install
npm start
# Open http://localhost:7860
```
## ๐ค Deploy to Hugging Face Spaces
1. Go to https://huggingface.co/new-space
2. Name: `drawable` | SDK: **Docker** | Visibility: Public
3. Clone the Space repo:
```bash
git clone https://huggingface.co/spaces/YOUR_USERNAME/drawable
```
4. Copy all project files into the cloned folder
5. Push:
```bash
git add . && git commit -m "init" && git push
```
6. Wait ~2 min for build. Your game is live! ๐
> **Note:** Hugging Face Spaces expose port 7860 automatically โ no config needed.
## โ Do I need a database?
**No!** All game state is stored in-memory on the server.
- Rooms exist while players are connected
- Scores reset each game
- No user accounts needed โ just pick a name and play
If you want persistent leaderboards later, add Supabase (free tier) and a `/leaderboard` endpoint.
## ๐ฎ How Rooms Work
```
Player โ click "Quick Play"
Server: any open room? โ YES โ join it
โ NO โ create new room, wait for others
Player โ click "Create Room" โ get 6-char code โ share with friends
Player โ click "Join Room" โ enter code โ join instantly
``` |