# Snoopy Tennis — Game & Watch (browser replica)

A faithful, fully-playable recreation of Nintendo's 1982 **Game & Watch Snoopy Tennis (SP-30)**,
built for modern desktop and mobile browsers. The physical console (bezel, buttons, purple
border, gold face, labels) is HTML/CSS; every character and animation is drawn live on an
HTML5 `<canvas>` — no sprite images.

Target host: **snoopytennis.com**

## Run it

No build step, no dependencies. Either:

- **Just open** `index.html` in a browser (works from `file://`), **or**
- Serve the folder (recommended, closest to production):

```bash
npx serve .
# or
python -m http.server 8080
```

Then open the shown URL.

## Deploy

It's a static site — upload the whole folder (`index.html`, `css/`, `js/`) to any static host
(Netlify, Vercel, GitHub Pages, S3, nginx, Apache). No server code required.

## Controls

| Action | Keys |
| --- | --- |
| Move Up | ↑ or W |
| Move Down | ↓ or S |
| Hit / Return | Space, Enter, J, or ← |
| Game A (easier) | A or 1 |
| Game B (harder) | B or 2 |

On touch devices, use the on-screen red HIT / UP / DOWN buttons and grey GAME A / GAME B.
ALARM / ACL / TIME are decorative (greyed out), matching the original.

## Screen size

Top-left buttons switch the console between **50% / 80% / Full** of the window.

## Project layout

```
index.html          Console shell (HTML) + script includes
css/styles.css      All styling; console scales as one unit via em units
js/audio.js         WebAudio beep engine (piezo-buzzer feel)
js/sprites.js       Procedural characters, digits, miss markers
js/renderer.js      LCD geometry + coloured background art + scene draw
js/input.js         Keyboard + on-screen button → game actions
js/menu.js          Popup menu + modal pages (Share/Instructions/…)
js/game.js          Game engine: state machine, ball physics, scoring
js/main.js          Boot, responsive sizing, fullscreen, error handling
```

Everything is namespaced under `window.ST`, loaded via ordered classic `<script>` tags
(so it also runs directly from `file://`).

## Gameplay

You are Snoopy by the tree. Charlie Brown serves balls high/middle/low — move Snoopy to the
right height and press HIT as the ball reaches his face. Charlie's returns score 2, Lucy's
2×-speed smashes score 3. Three misses (broken bottles) end the game. Hit 200 or 500 points
in a 1000-point cycle to clear misses and trigger CHANCE TIME (5/6 points). Score rolls over
at 9999. Not playing? It's a clock.

_Fan tribute. Peanuts characters © Peanuts Worldwide LLC. Not affiliated with Nintendo._
