# Coast Ride: A 3D Seabird Bike Ride from Dusk to Starry Night

> A playable 3D game in one offline HTML file: a pelican in a helmet, sunglasses and a cloth-simulated scarf rides a bicycle along a coastal road and catches fish. Change lanes, jump for golden fish, spread its wings for a wheelie, and ride on as the sky turns from golden dusk to a starry, moonlit night beside a breaking surf. One ride file turns it into a puffin, a heron or your own bird.

- Type: Lab Skill (downloadable Agent Skill)
- Category: [Game creation](https://www.sandbase.ai/skills/games)
- Version: 0.1.2
- Runs online: yes
- Page: https://www.sandbase.ai/skills/games/coast-ride

## What you get

Bring edits to an example ride: the bird and its colours, the helmet, glasses and scarf, what it catches, the hours of the sky and the coast. The Skill returns a downloadable Skill (the three.js game, a ride config, a customize guide, headless verification) and three playable example rides.

## Install

Download the Skill package from https://www.sandbase.ai/skills/games/coast-ride (sign-in required), unzip it into your agent's skills folder, then ask your agent to use it:

```text
/coast-ride make a coastal bike ride with <your bird, its colours and gear, and what it catches>
```

## How it works

1. **Copy and restyle a ride** node scripts/new-project.mjs --out <dir> copies the project, with Node 22.4 or later. Copy rides/pelican-dusk/ to a new id and edit its ride.json; references/customize.md maps every field to what changes on screen and names the code to edit for deeper changes, such as the rider's body, the cameras, the jump height or the achievements.
2. **Build one file** RIDE=<id> npm run build:single writes dist-single/index.html with three.js inlined and no fetch, storage or external URLs, so it runs in a sandboxed frame or opens from disk with a double-click. No key is needed and nothing calls a model.
3. **Verify every check** npm run shoot writes shots/report.json and screenshots; every step in verify.json must reach its asserted state, and facts.colours echoes the ride's colours so an agent can confirm the restyle without seeing images. Each published ride passed 30 checks at 60 fps. Node tests also check the ride schema, the day cycle and the lane-change curve.

## FAQ

### How do you play Coast Ride?

Press Start riding, hold W to speed up and S to slow down, and tap A or D to move between the three lanes. Fish leap across the road: ride under one to catch it in the beak. Golden fish fly high and need a jump with Space, and rocks cost your combo unless you jump them. Hold T to spread the wings for a wheelie. Leave the keys alone for six seconds and the autopilot rides for you.

### Can the rider be a different bird?

Yes. The rider is one parametric bird, and the three examples are a pelican, a puffin and a heron built from the same code. A ride.json sets the feather, back, wing-tip, beak, feet and eye colours, the beak and neck length, and whether it has a crest and a throat pouch. A body of another shape, such as a penguin, means editing the geometry in src/pelican.js; the IK and the scarf follow.

### Does Coast Ride call a model or the network?

No. Every mesh, texture and sound is generated in code when the page loads, and the page makes no network requests. Building a new ride needs only Node and npm, and verifying it needs a local Chrome. No SandBase key or paid call is involved.

### Does it work on phones?

Yes. Touch buttons change lanes, jump, hold the wheelie and change speed, and quality starts at medium and adapts to the measured frame rate. It was verified under touch emulation at 390×844, not on real devices, so check it on the phones you care about before sharing it.

### Why is the scarf a cloth simulation?

Because it is the thing that shows motion best: it streams back as the bike speeds up, swings out on a lane change, lifts on a landing and settles when you coast. Two cloth strips with body colliders cost little enough to run on phones too.

## Examples

- Coast Ride 3D bike ride game (scene)
- Puffin Island Sprint (scene)
- Heron Lagoon Loop (scene)
- Pelican Coast Ride (video)
- Puffin Island Sprint (video)
- Heron Lagoon Loop (video)
