# Wheat Before Rain

> An upland wheat field under a building storm: gust fronts roll across thousands of painted stalks as bands of light and shade, and the crop parts and flattens under your hand.

- Type: Lab Skill (downloadable Agent Skill)
- Category: [Interactive 3D](https://www.sandbase.ai/skills/interactive-3d)
- Version: 0.1.1
- Runs online: yes
- Page: https://www.sandbase.ai/skills/interactive-3d/wheat-before-rain

## What you get

Bring a field, a sky and the weather to move through it. The Skill returns a downloadable Skill and a runnable wind-in-wheat scene.

## Install

Download the Skill package from https://www.sandbase.ai/skills/interactive-3d/wheat-before-rain (sign-in required), unzip it into your agent's skills folder, then ask your agent to use it:

```text
/wheat-before-rain build a wind-in-the-crop scene of <your field and weather>
```

## How it works

1. **Build the storm-field page** Wheat Before Rain builds with npm install, which brings playwright-core for the checks only, then npm run build for a bilingual dist/index.html or npm run build:zh for the squall-zh Chinese brief. The page is Canvas 2D drawn by code with no image assets or network requests: a ripe upland wheat field under layered storm cloud, with an oak, telegraph poles, swallows, a hedge and a farmhouse.
2. **Drive stalks from a wind grid** A coarse perspective wind grid in src/field.js carries gust fronts that pale the crop ahead and darken it behind. Each stalk is a damped spring whose tip chases the sampled wind. Drag to comb the crop, flick or press G to throw a squall uphill, hold to part the ears and tap or press L to flush a skylark. A 180 second weather loop runs six turns.
3. **Shoot the wind and verify** npm run shoot asserts in headless Chrome with the network blocked that grid rows densify toward the horizon, a front is pale ahead and dark behind, a squall travels and expires, a puff decays, stalk bend rises under a gust and tone varies across the field. It writes dist/shoot-report.json and shoot-field.png. verify.mjs then proves five live interactions under the sandbox CSP.

## FAQ

### What does Wheat Before Rain show?

Wheat Before Rain shows a ripe wheat field under a building storm, with poppies and cornflowers in the crop, a lone oak, swallows on telegraph wires, a rain shaft and light breaking through cloud. Gust fronts roll across the crop as moving bands of light and shade from the first second, and your pointer adds squalls of its own.

### Is the wind in Wheat Before Rain simulated?

Yes. Wheat Before Rain moves gust fronts and pointer squalls across a perspective wind grid, and each stalk is a spring that leans with the wind sampled where it stands. The far and middle crop are baked into depth strips sheared by the wind, so they sway in bands; only the nearest rows are drawn stalk by stalk.

### Does Wheat Before Rain need a key?

No. Wheat Before Rain draws the field, sky and birds in code with no runtime model calls, image assets or network requests. playwright-core is installed only for the headless checks, so the scene carries no SandBase charge.

### What changes the sky in Wheat Before Rain?

Wheat Before Rain runs a fixed 180 second weather loop of six turns, from calm through gusts, rain and thunder to clearing. The chip at the top left names the current turn and hurries the sky to the next one. The weather is a loop, not a forecast, and the landscape is illustrative.

### How fast does Wheat Before Rain run?

Wheat Before Rain ran near 45 to 55 fps full-screen at 1600 by 900 in headless Chrome without a GPU, after dropping to a coarser backing store in its first frames. Capture mode, set with ?capture=1, keeps full resolution and lets a recorder drive frames through window.__scene.

### Does Wheat Before Rain work on a phone?

Yes. Wheat Before Rain responds to swiping, holding and tapping the same way as to a pointer. With reduced motion turned on, the gust fronts and rain stop and only a light breeze stays.

## Examples

- Wheat Before Rain storm field (scene)
- Squall over the Wheat (video)
