chore: bootstrap Claude setup

Add root CLAUDE.md, docs/ (game-rules.md, release.md), LESSONS.md and
.env.example; trim README.md to a landing page linking to docs/.

No linter, test runner or formatter is configured for this static
HTML/CSS/JS project, so no .claude/settings.json hooks or CI workflows
were added: there is nothing to run. CI (asset versioning + Android
APK build/release) already exists in .gitea/workflows and
.github/workflows and is documented in docs/release.md as-is, since
there is no development branch to drive the standard version.yml flow.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
dasemuandClaude Sonnet 5 committed 2026-10-18 15:02:58 +02:00
1 parent e6ef7818da
commit 7a08b89799
7 files changed
+90 -66

No files matched your search

+8 -66
View File
@@ -1,52 +1,16 @@
# Impostor Game (offline)
## What is it?
Role-based impostor-style game for mobile, 100% in the browser with no backend. Uses localStorage so a reload doesn't lose the match. Features **impostor-specific words** for each civilian word to make the game more challenging!
Role-based impostor-style game for mobile, 100% in the browser with no backend. Uses localStorage so a reload doesn't lose the match. Features **impostor-specific words** for each civilian word to make the game more challenging! 22 word-pool categories are available, and you can select several at once.
## Structure
- `index.html`: main UI.
- `styles.css`: mobile-first, no-scroll optimized styles.
- `script.js`: game logic (roles, timers, voting, tiebreaks, word pools with impostor variants).
- `word-pools/`: 22 word pools in `.txt` + `manifest.json`.
- `www/index.html`: main UI.
- `www/styles.css`: mobile-first, no-scroll optimized styles.
- `www/script.js`: game logic (roles, timers, voting, tiebreaks, word pools with impostor variants).
- `www/word-pools/`: 22 word pools in `.txt` + `manifest.json`.
- `android/`: Capacitor-generated Android project.
## Available pools (22 total)
### Local pools (work offline, embedded in code):
- 🌿 Animales y Naturaleza (88 words) — `animales_naturaleza.txt`
- 🏠 Objetos Cotidianos (99 words) — `objetos_cotidianos.txt`
### Remote pools (require internet connection):
- 🛍️ Marcas y Empresas (81 words)
- 💼 Profesiones y Trabajos (94 words)
- 🍕 Comida y Bebidas (145 words)
- 🌍 Lugares del Mundo (89 words)
- ⚽ Deportes (97 words)
- 🎬 Películas y Series (118 words)
- 📚 Escuela y Educación (114 words)
- 💻 Tecnología e Internet (63 words)
- 🚗 Vehículos y Transporte (97 words)
- 🎸 Instrumentos Musicales (106 words)
- 🎮 Videojuegos (128 words)
- 🎌 Personajes de Anime (133 words)
- 🏰 Personajes de Disney (133 words)
- 🎤 Artistas Latinos (116 words)
- 💎 Marcas de Lujo (108 words)
- 🦸 Personajes de Ficción (124 words)
- 🫀 Cuerpo Humano (129 words)
- 🏖️ Playa y Verano (69 words)
- 💕 Amor y Romance (98 words)
- 🎄 Navidad y Fiestas (88 words)
**New feature:** You can select **multiple pools** simultaneously to mix categories!
`.txt` format: `# Header` on first line (optional), then `civilian_word|impostor_word` pairs, one per line.
## Key rules
- Defaults: up to 10 players; impostors by player count (<=5 →1, 6-7 →2, >7 →3) and never more than half.
- Time defaults: 5 min with 4 or fewer players, up to 15 min with 10; deliberation = 1/3 (rounded).
- No self-voting. Max executions = number of impostors.
- Tie on execution slots: 1 extra minute of deliberation and a new vote only among tied players; if tie persists, impostors win.
- Starting player and direction (clockwise/counter-clockwise) are random.
See `docs/game-rules.md` for the full rules and word-pool format, and `docs/release.md` for how builds and releases work.
## How to run (offline)
Use any static file server so `fetch` can read the `.txt` files (needed if opening via `file://`). Example with Python:
@@ -59,27 +23,5 @@ python -m http.server 8000
Open in browser: `http://localhost:8000`
## Word format with impostor variants
Each word pair consists of:
- **Civilian word**: What most players see
- **Impostor word**: A related but different word that impostors see
Example from `animales_naturaleza.txt`:
```
Oso|Pez
Camello|Arena
Elefante|Safari
```
This makes the game more interesting as impostors have a related word to work with!
## Add new pools
1) Create a `.txt` in `word-pools/` with optional header `# Name` and pairs `civilian|impostor` per line.
2) Add an entry in `word-pools/manifest.json` with `id`, `name`, `emoji`, `count`, and optionally `local: true`.
3) (Optional) To make it work offline, add an embedded version in `script.js` `EMBEDDED_POOLS` array.
## Notes
- State is saved in `localStorage` (`impostorGameStateV2`). Use "New match" to clear it.
- Mobile optimized: **No scrolling required** on setup screen, reveal via swipe or tap, compact adaptive UI.
- Pool selection grid has vertical scroll when needed to fit all 22 categories.
For Android, see `docs/release.md`.