# Changelog

Every release of the Controller+ SDK, newest first. From 0.9.1 on, each entry lists the SDK's own changes first and marks any **breaking** change; demo games (`examples/games`) and the docs follow apart. Earlier entries group their changes by area.

## 0.21.0 (15 November 2026)

**SDK.** One change in behaviour: `RelayRoom.close()` now ends the room on the relay.

- **`room.close()` ends the room on the relay**, so its phones leave and it stops counting against your network's open rooms at once. Before, a closed room stayed on the relay for up to 30 minutes, and a page reloaded while you develop could fill its network's 24 rooms. `close({ keep: true })` keeps the old behaviour for a page that attaches to its room again after a reload ([the recipe](docs/sdk-relay-host.md#keep-a-room-across-a-page-reload)).
- **`room.joinCode`**: six characters a player can type under **ENTER CODE** instead of scanning. The relay registers one with every game's room. `room.code` is the room's id on the relay, which no phone could type. `null` from a relay that registers none.
- `createRoom` stops the half-built room's timers and listeners when connecting fails.
- **The test driver opens a relay room's `room.joinURL`**: `openPhone` and `openPage` wait for the page a tab ends on after a page sends itself on with a script, and `openPage` takes a `file:` URL for a game opened from disk ([test a browser game](docs/testing.md#test-a-browser-game)).
- **Browser controller:** REPORT A PROBLEM on the start screen opens the report (it did nothing); **Get Pro** in MENU opens a screen about Pro instead of the contact screen; pressing A on **Connection details** no longer opens and closes it at once; controller.plus's own copy of the controller sends problem reports to hello@controller.plus.
- **The archive carries its runtime packages** (`ws`, `qrcode`, `jsqr`, `js-sha256` and what they use), so installing it or running its examples never reaches the npm registry. It also ships `assets/layouts.json`, which its own protocol test reads.
- **Engine packages:** each carries the final SDK licence (they had a draft); the Unity package ships its `.meta` files, without which Unity ignores a package installed from a tarball; the Godot download leaves out tests that only run inside the whole kit; the Python package imports without `websocket-client`, which only `HostConnection` needs; README links point at the published docs.

**Hosted relay (controller.plus).** A room nobody is connected to ends after 5 minutes, or 30 while a phone that dropped out still has its seat kept. A refused room or request carries `Retry-After: 60`; a refused socket gets 403 or 503 with a reason instead of being dropped; a game attaching to an ended room is told `room_expired` before the close, so engine packages stop retrying. The relay takes the `instruments` readout command engine packages send. Two phones with the same name are told apart (the second becomes "Player 2").

**Demo games.** Gamepad Demo's card shown before anyone joins says "Scan the QR to play" (it said "Reconnect to play").

**Docs.** After an outside review: the limits per network and how rooms count; the relay's room API for engines and servers; the errors sent before a close; what Controller+ receives from your players; pinning a browser game by copying `src/`, and what stays live; removal on relay rooms; a test recipe for browser games; the route engine games get; steps for Android's Bluetooth mode; and corrections across the guides.

## 0.20.1 (15 November 2026)

**SDK.** No breaking changes.

- **A browser phone on Android aims without steps.** Chrome fires `deviceorientation` only once the phone has turned a tenth of a degree (checked on Android Chrome 134: 41 events in 12 seconds against 60 a second from the sensor), so a slow aim on a browser phone moved in steps of about 7 px on a 1080p TV. The browser Remote now reads the same orientation from `RelativeOrientationSensor` where the browser has it, 60 times a second, and keeps `deviceorientation` wherever that sensor is missing, refused, failing or silent. Both give the same quaternion in the same frame (checked), so a change of source never moves the aim. Checked on Android Chrome: during turns of 0.03 degrees the game received 100 different poses where `deviceorientation` fired 57 times.

**Demo games.**

- **Shooter Demo and Run and Gun Demo: a shaking hand hits what the crosshair showed.** A shot is judged by where the gun pointed on average over 0.1 s (`RULES.steady`), centred 70 ms before FIRE as before, instead of at one instant: a hand twitching 4% of the screen to either side of a can hits it, and a hand held 4% to one side still misses. The crosshair is unchanged.
- **A reload no longer buzzes for every chamber.** The ticks as the cylinder fills are sound only; the clack that closes it still buzzes. (A browser phone on Android had buzzed six times a reload, all at full strength.)
- `phoneCue(game, player, cue, rumble, { vibrate: false })` in `examples/games/common.mjs` plays a cue's sound with no vibration (it sends an empty pattern, which every phone honors).

**Docs.** *Ship a game* states the terms of our hosted relay: free for games with fair use, rooms up to six hours, at least 90 days' notice on controller.plus before any change that would break a game that works today, no uptime guarantee.

## 0.20.0 (15 November 2026)

**SDK.** No breaking changes.

- **`trackPlayers(room, { create, joined, changed })` keeps one record per seat** of a room from `createRoom` or a `ControllerHost`: its name, whether it is connected, its newest input (neutral whenever the phone is away or the page has lost the relay), network and route, and the game's own fields from `create`, which stay through every return. `joined` runs when a phone takes its seat or comes back, `changed` when who is here or how changes (never for input); `players.online` says whether a room's page has its relay; `players.close()` stops listening. It replaces the thirty-odd lines of `join`, `disconnect`, `removed`, input and reconnect bookkeeping every example repeated, and the examples disagreed on (an outside developer's review). Exported from `relay-host` and the package root, with types. Tested on a relay room and on a ControllerHost with real phone sessions.

**Docs.** The web-game guide's example uses `trackPlayers`; the relay-host reference has a section on it; the agent guide's second rule starts with it.

## 0.19.1 (15 November 2026)

**SDK.** No breaking changes.

- **The browser controller's game vibration has strengths.** A browser can only vibrate at full strength, so every cue a game sent buzzed as hard as a hit: in Shooter Demo a reload tick (0.22) or the click of an empty gun (0.18) as hard as a shot (0.9), five ticks to a reload. Each pulse now lasts its share of its strength, never under 8 ms, the shortest a phone's motor is felt at: a shot 54 ms, a reload tick and the empty click 8 ms. `vibrationSteps(pattern)` in `web/feedback.mjs` turns a cue's pattern into `navigator.vibrate` steps. Browsers vibrate on Android; Safari on iPhone does not.

**Docs.**

- The Markdown pages are plain Markdown, with no style block and no table wrappers; controller.plus lays its tables out for phones itself.
- Links into the SDK's own files (the license, the example and engine READMEs, the test kit) work on controller.plus, where they point into `/sdk/`.
- The web-game guide's first run needs no server: open `game.html` from disk or from any site; serving a pinned copy is the step before a release.
- *What works where* explains versions and compatibility for game developers; how releases are tested against recorded older apps stays in this repository's `docs/compatibility.md`.
- *Connection quality* has one table for the three names of each route (`connection.route`, the `route` event, the words on the phone).
- The adapter-only part of the relay-host reference (host extensions, seat lifecycles, peer handoff) has its own page, *Writing a host adapter* (`sdk-adapters.md`).
- A key's `image` and a view's `minApp` are marked as doing nothing yet.

## 0.19.0 (13 November 2026)

**SDK.** No breaking changes.

- **Held upright, the Remote's stick for the other thumb is in the top corner too, a controller's size.** With `stickHand: 'other'` the stick no longer drops to the keys' deck on a phone held upright: it sits in the top left corner (top right for a left hand), a well of up to 150 pixels, the four small keys two by two beside it (CENTER, VIEW; MOTION, MENU), 40 pixels clear of it; the status screen keeps its width 40 pixels under it, then the aim glass, then FIRE and CALIBRATE low by the hand. Screens too narrow for a 100-pixel well and two 52-pixel keys keep the stick on the deck. `remoteLayout(...).keys.columns` is `2` then.

**Demo games.**

- **Run and Gun Demo's view follows the phone without jitter.** Phones on Wi-Fi and relays deliver their samples late and in bursts; the view, drawn 25 ms back from whatever had arrived, stood still and then jumped. The game now draws the phone's pose as far in the past as its samples have lately been late (up to 40 ms), so there are samples on both sides and the view moves smoothly between them; when a sample is later still, the newest is carried on by how fast the phone was turning, for at most 50 ms, and back to the newest sample if the phone stays silent, so a stop or a pause is not overshot (`followPose`, `turningOf` and `turn` in `examples/games/town-view.mjs`; the game's own aim uses the same pose). Measured in the game with samples every 10 ms: with Wi-Fi bursts every 60 ms the view is about 7 times smoother than before (its roughness against the hand's own movement 4.3 instead of 29) for 8 ms more delay; through a relay with 100 ms bursts about 12 times smoother; on steady Wi-Fi 42 ms behind the hand instead of 48; a quick pan that stops overshoots by under half a degree. A test plays these routes. (A tracker that carried the view on further was quicker, but overshot a stopping hand by 3 to 7 degrees, and was not kept.)

## 0.18.0 (13 November 2026)

**SDK.** No breaking changes.

- **Four corners line a gun up better, and are the default.** `AIM_CORNERS` names the four corner targets, clockwise from the top left, and `aimMap([four shots], {centre, ...})` makes a map that gives each half of the screen its own size. Sitting to one side of the TV makes its near half look larger; with the screen 1 m to the side of a player 2.4 m away the aim between the targets now misses by at most 3.5% of the screen instead of 9%. Each half is measured twice, so shots up to half a degree off miss by about a quarter less. Two corners stay available for a quicker line-up (`AIM_TARGETS`, `aimMap(first, second)` or `aimMap([first, second])`). Run and Gun Demo lines up with the middle and four corners; Shooter Demo keeps its quick three shots.
- **The phone shows the line-up too:** a Remote view may carry `aimAt: [u, v]`, the spot of the game's screen to point the phone at. With motion on, the Remote's aim glass shows "AIM AT THE TV" and a little person, drawn like a sign, aiming the phone at that spot of a TV, from the hip and then held up like a gun, with "SHOOT IT HOW YOU'LL PLAY" under it. Both gun games send it during their line-up; `validateRemoteView` checks it.

**Demo games.**

- **Run and Gun Demo plays like a first-person shooter: the crosshair stays in the middle of the screen and the view follows the phone.** Pointed at a spot on the screen, the view turns until that spot is in the middle; pointed at the middle, it looks straight ahead; pointed past the left or right side, it keeps turning that way (`lookFrom` in `examples/games/town-play.mjs`). A shot goes where the middle of the view was a moment before FIRE went down. On the aim glass a finger drags the view; the keyboard's view comes round by itself to what is in sight. The state's `hero` gains `base` and `tilt`, the heading the view turns from; the rules' `turn.band` gives way to `turn.past`, `turn.glass` and `turn.track`.
- **The line-up shows how to aim, with people:** two cards under the target show a person aiming the phone at it, one from the hip and one held up like a gun, swinging round to each new target and firing as it jolts. Above them: "Hold it the way you'll play, from where you'll play"; under the first target's words, why: "These shots show the game where your screen is". The target to shoot pops up on a stick, sways, and four gold brackets close in on it. After the first shot the screen says CALIBRATE on the phone starts again. Both gun games share it (`drawLineup` in `examples/games/hold-picture.mjs`); the close-up of hands round a phone is gone.
- The phone's screen names each corner target ("AT THE TOP RIGHT"); the line-up's `lined` effect says `step: 'done'` when it is finished.

## 0.17.0 (13 November 2026)

**SDK.** No breaking changes.

- **The Remote's stick for the other thumb sits in the very corner** of the far end of a phone held sideways, as large as a controller's stick (a well of 150 pixels at full size), with 40 pixels clear round it: the status screens and the small keys move over and narrow to make room, to 200 pixels at the least, and their words shrink to fit. A touch anywhere in its corner takes the stick. Before, the stick sat on a small deck of its own right beside the screens and the small keys.
- **Every Remote stick is drawn as the gamepad's**: a well moulded into the plastic, in shade under its upper lip, and a dark cap with a dished top and a ring of ridges. It replaces the dark disc with a pale ring.

**Demo games.**

- **Run and Gun Demo is a first-person shooter.** You walk a little western town (a saloon, a general store, the sheriff's office, a water tower, a wagon) with the stick under your other thumb, and the phone aims. Holding the crosshair at the left or right edge of the screen turns the view, faster near the edge; at the top or bottom edge you look up or down. Outlaw boards flip up in the windows, on the porch roofs and behind the wagon, the barrels and the bales: shoot each before it fires (30 for a quick draw, 20 later; a board left standing costs 5). The first stands in front of you, later ones all round, up to three at once, with a ring over each that empties as its time runs out and arrows at the sides for those out of sight. Cans and bottles stand on three rails and refill; shot boards and cans drop stars to walk over; tumbleweeds come in where you look and roll at you, to be shot or stepped away from; the crate by the store still gives the gatling gun. The gun is drawn in your hand. A round lasts 90 seconds. The town is `examples/games/town.mjs`, its rules `town-play.mjs` and its picture `town-scene.mjs`.
- **How to hold the phone like a gun is drawn again** for both gun games (`examples/games/hold-picture.mjs`): the phone as the Remote shows it sideways, with the stick for a game that has one, and two hands whose thumbs rest on FIRE and on the stick.

## 0.16.3 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Run and Gun Demo says how to hold and play in three short sentences**: "Hold your phone like a gun. Run with the pad at its far end, under the thumb of your other hand. Aim with the phone and press FIRE with your thumb." The earlier sentence could be read as the thumb running.

## 0.16.2 (13 November 2026)

**SDK.** No breaking changes.

- **The Remote keeps CENTER when the game is gone; its VIEW key is DISCONNECT then.** 0.15.3 turned CENTER into DISCONNECT in that state, which took away the Remote's reset key, on its face in every state since 0.5.0. CENTER stays CENTER and still centres. VIEW turns red, reads DISCONNECT and leaves the room, and the status LCD says `GAME NOT RESPONDING` and `DISCONNECT TO LEAVE`. A press keeps the meaning it began with.
- **The word DISCONNECT fits its key.** At the size 0.15.3 gave it, it was wider than the key on every phone under 430 pixels wide. It is set in the lighter face, as large as the key allows (7 pixels on a 320-wide phone, 10 where there is room).

## 0.16.1 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Run and Gun Demo: a tumbleweed that gets to the ranger costs 5 points, not 10**, the same as shooting one earns. A first whole round on the live site lost every point it had made to five tumbleweeds, in the game that is meant to be the easier one.

## 0.16.0 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Run and Gun Demo** (`run-and-gun-demo`), sixth in the list of games, before Bumper Circuit. It is Shooter Demo's gun with a ranger to run about the sand in front of the fence: held like a gun, the phone aims and fires, and a stick under the thumb of the other hand runs. Its Remote view asks for that stick with `stickHand: 'other'`, so on a phone held sideways it sits at the top corner of the far end, apart from the keys. Cans drop stars to run for (10 points). A tumbleweed rolls in from behind the fence every 6 seconds, hops over it and on to where the ranger stood: a step to the side or a shot (5 points) stops it, and it costs 10 points if it gets there (5 from 0.16.1). A gamepad runs with its left stick and aims with its right; on a keyboard the arrow keys run and the ranger aims at whatever is nearest.
- **It is the easier of the two shooting games.** A shot counts from 0.03 of the screen's height around a standing target (Shooter Demo: 0.012) and from 0.055 to 0.079 around a can in flight, the crosshair turns gold when a shot from where it is would hit, the gun reloads in 0.6 seconds and a round lasts 75.
- `project`, `sizeAt`, `sight` and `landing` of `examples/games/shooter-range.mjs` take the camera to work with as a last argument (Shooter Demo's own unless given); `startShooterHost` takes the game module to host. See [the game's guide](docs/run-and-gun-demo.md).

## 0.15.3 (13 November 2026)

**SDK.** No breaking changes.

- **A Remote can have a stick for the other thumb: `stickHand: 'other'`.** On a phone held sideways like a gun, the stick then sits at the top corner of the far end, apart from the keys, so one thumb moves a character while the other hand aims and fires. Upright, or on a screen too short for it, the stick stays on the keys' deck. Such a view is shown as the game names it, whatever Remote settings the player has saved. Older phones ignore the field.
- **The Remote's CENTER key is DISCONNECT when the game is gone.** The other controllers turn SELECT into DISCONNECT when a game's page is closed or reloaded; the Remote has no SELECT and only said where to find it in the menu. (Changed in 0.16.2: the key is VIEW, and CENTER stays CENTER.)

## 0.15.2 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Gamepad Demo is second in the list of games**, after Racket Demo; Shooter Demo, Plane Demo and Car Demo follow.

## 0.15.1 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Shooter Demo shows how to hold the phone.** The line-up screen draws the phone on its long edge in two hands, as a gun is held: one hand around its near end with the thumb on FIRE, the other under it, the far end pointing at a small screen, with the side the screen faces written out (left for a right hand, right for a left hand). It replaces a drawn phone that turned towards each target and showed its screen from the wrong side for the third one.

## 0.15.0 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Shooter Demo: a gatling gun.** An ammunition crate stands at the bottom left of the range. Shoot it and the gun is a gatling for the rest of the round: hold FIRE for 14 rounds a second from a belt of 200, then 1.6 seconds of reloading. The rounds scatter around the crosshair, wider as the barrels heat up, and every fifth is a tracer; the phone rumbles with them. A can takes one round at most every tenth of a second, and the rounds pay half of the six-shooter's for six hits at the most. New state: `gun`, `crate`, `heat`; new rules under `RULES.gatling`.

## 0.14.2 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **A quick tap is never lost.** The example games looked at the keys once per step of the game. A whole tap that arrived between two steps (a very quick one, or any tap while the page was busy for a moment) was never seen, although the phone had clicked. `connectGame` now keeps each button's highest value since the last step for the first slice of the next one.
- **Shooter Demo: CENTER lines the gun up again.** At any time: aim at the middle of the screen, press CENTER, then shoot the two corner targets; the round waits and a count from 3 follows. Until now CENTER only moved the crosshair to the middle and kept the old size of the screen, which is no help to a player who has moved.
- **Shooter Demo: more help with cans in flight.** The shot assist allows 0.03 to 0.054 of the playfield's height around a flying can (was up to 0.026), and counts where the can was and will be 50 milliseconds either side of the shot. Standing targets are as before.
- **Shooter Demo: the gun is heard and felt in the hand.** The phone ticks as each chamber fills, clacks when the gun is loaded, and an empty gun gives a click of its own on the phone and on the screen (it sounded like a hit on wood).

## 0.14.1 (13 November 2026)

**SDK.** No breaking changes.

- **A Remote held sideways has its trigger at the top.** Held like a gun, a phone stands on its long edge and the thumb comes over the top edge at the end the hand holds. With two keys and no stick, the first key is now the upper one there, and its deck sits at the top, against that end. On an 844 by 390 phone the key starts 63 pixels below the top edge and ends 85 pixels from the hand's end; it was in the lower half. Upright nothing changes.

## 0.14.0 (13 November 2026)

**SDK.** No breaking changes. Two defaults changed: `steadyAim` steadies less, and `aimAxis` prefers the top edge (below).

- **Aiming reads the barrel from the shots, however the phone is held.** Players hold a phone like a gun: on its long edge, the screen to the side, a thumb on the trigger key. Until now the line of the phone that points was guessed from one pose (the flatter of its top edge and its back). On its edge that guess was the back, which points sideways: the gun turned left and right but could not aim up or down. New `aimBarrel(centre, first, second)` reads the barrel from the three shots of a line-up: the line that stayed near level and tipped down from the top left target to the bottom right one, with either end of the phone forward. `remoteAim` takes any of six lines (`top`, `bottom`, `back`, `front`, `right`, `left`) or a direction, and an orientation in place of an input. `aimAxis` is now only a first guess from one pose: the top edge while it is within 60° of level, in any roll.
- **`aimMap` takes the picture's shape (`aspect`).** A side the phone hardly moved along is taken from the other side and that shape, not from the least size.
- **`steadyAim` is light by default**: 5 Hz at rest (was 1.2), 60 Hz more per radian a second (was 10), and a `sense` option. A crosshair must not hang behind the hand.

**Demo games.**

- **Shooter Demo is held like a gun**, and says and shows so. It keeps every pose the phone sends with the phone's own time, as Racket Demo does: the crosshair is drawn from the pose a moment ago carried on by its own turning, and a shot is judged 70 milliseconds before its key went down, whenever the game happens to step. Its state gains `drawPose`; `axis` is one of the six lines; `centre` and `first` are no longer public.

## 0.13.4 (13 November 2026)

**SDK.** No breaking changes.

- **A word on a Remote key is never broken inside itself.** On the smallest phones (320 pixels wide) a long word such as Calibrate ran onto a second line after its eighth letter. The letters now give way instead, to 8 pixels at the least. Larger phones are unchanged. This is the browser controller; the phone apps follow in their next builds.

## 0.13.3 (13 November 2026)

**SDK.** No breaking changes.

- **A Remote view can say the phone is pointed at the screen: `hold: 'point'`.** The phone then shows nothing about the upright pose: no CENTER lamp, no HOLD UPRIGHT TO CENTER under the 3D phone, no tick when it passes through upright. Shooter Demo sets it: its phone said HOLD UPRIGHT TO CENTER while the game said to hold it like a TV remote. The CENTER key still sends `remote-center`. `hold: 'upright'` is the default, and older phones ignore the field.

## 0.13.2 (13 November 2026)

**SDK.** No changes.

**Demo games.**

- **Shooter Demo's line-up record says what the phone did.** `lineup` gains `right` and `down`, the degrees the phone turned right and tipped down from the second target to the third, before any least size, and `level`, how far above level it pointed at the first. A host can now tell a screen that really looks small from a hand that moved without turning the phone.

## 0.13.1 (13 November 2026)

**SDK.** No breaking changes.

- **A Remote with two keys and no stick has a trigger.** The first key is larger (150 units, was 124), and its deck sits low and against the side of the hand that holds the phone, so the thumb reaches it without stretching. It keeps the least margin of the deck around it (30 units, 16 pixels at its smallest). Shooter Demo's FIRE is this key. With a stick, or with one key, the layout is as before.

**Docs.** **Remote motion on iOS** is documented as the gyroscope and the accelerometer alone (`xArbitraryZVertical`). The compass-corrected frame turns the heading near computers, TVs and speakers.

## 0.13.0 (13 November 2026)

**SDK.** No breaking changes.

- **Aim helpers**: `aimAxis(input)` says which line of the phone the player points with (`top` or `back`), `remoteAim(input, axis)` reads it, and `aimMap(first, second, {centre, least})` takes a shot at the middle of the screen and a least screen size. Without the new options they behave as in 0.11.0.

**Demo games.**

- **Shooter Demo, the line-up redone.** The first one did not work in a real hand: the phone had to be held upright and aimed with its back, which nobody can sight along, and a second corner shot that was too close to the first was refused. Now the phone is held like a TV remote and its top edge is the barrel. Three targets are shot one after the other (the middle of the screen, its top left, its bottom right), and the gun always works after them: shots that are too close together give a screen of the least size a hand can aim at (16° by 9°) and a tip to turn the phone itself. Each shot is read from just before the press, which pushes the phone. A phone held upright still works; its back leads then.
- **The explanation on the screen** is one target at a time with one sentence ("Point your phone at the target and press FIRE"), a phone that points at it, and how to hold it. The panel with three steps and a side-view diagram is gone.
- The game's state has `axis` and `lineup` (what the last line-up measured: the screen's size in degrees as seen from the player, and where the shots were too close). `steadySince` is gone, and the Remote view no longer asks for the upright ready pose.

## 0.12.0 (13 November 2026)

**SDK.** No breaking changes.

- **Two parts on a side**: a built controller's side can hold a stick or a D-pad under its buttons, or a stick under its D-pad. Each is a part of its own: `dpad-over-stick`, and `buttons-2`, `buttons-4`, `buttons-6` and `buttons-9` `-over-stick` and `-over-dpad` (four buttons over a stick is still `stick-buttons`, a stick over a D-pad `stick-dpad`). The upper part sits where the Two sticks layout has its face buttons or its upper stick, inside the same circle; the lower one where that layout has its lower stick or D-pad. A stick that shares its side clicks (L3, R3). Every one of the 867 combinations is laid out and checked on each screen shape: 44 point targets, nothing overlapping, everything on the shell.
- **Older phones**: a phone that does not know one of the new parts ignores the request and shows the nearest built-in layout, as it does for any part it does not know. `knowsTwoParts(rows)` reads that from a phone's settings report and `needsTwoParts(parts)` says whether a combination needs it.
- **Pickers**: `sideChoice(parts, side)` gives a side as its first part and the one under it, `under(first)` what can go under a part, `withSide(parts, side, first, second)` the combination a new choice gives, and `pairPart(first, second)` the part itself. The browser controller's own menu shows **Left side** and **Left second part** (and the same for the right) for the report's one row.
- **No room**: where a screen cannot fit a side's second part with 44 point targets, that part is left out and the side is laid out with its first part alone (`fit.dropped` lists the sides); every other control still sends what the whole combination says. Of the screens checked this happens in one case: a D-pad under nine buttons on the small body of a 667 x 375 phone or a notched 800-wide screen.
- Over a second part the nine's touch targets are the discs inside its cells; alone they stay the square cells.

## 0.11.0 (12 November 2026)

**SDK.** No breaking changes.

- **Aim at the screen**: a Remote can be pointed at the screen like a light gun. `remoteAim(input)` gives where the back of the phone points, `aimMap(first, second)` turns a shot at each of two corner targets (`AIM_TARGETS`) into a map for that screen at that distance, `aimPoint(map, pointing)` gives the point on the screen, `aimCentre` follows the phone's CENTER, and `steadyAim` takes the tremble out of a hand without making the aim lag. All plain data, exported from the root and `/remote`. See [Remote](docs/remote.md#aim-at-the-screen).

**Demo games.**

- **Shooter Demo** (`shooter-demo`): hold the phone upright and face the TV, shoot the target in the top left corner and the one in the bottom right, and the crosshair is where the phone points. Then a 60-second round: knock cans off a fence and hit them again in the air for more, break bottles, six shots and a reload. The crosshair never leaves the screen, a small shot assist is on unless it is turned off, CALIBRATE runs the line-up again while the round waits, and play goes on after a count from 3. Works with the aim glass, a gamepad and a keyboard too. See [the guide](docs/shooter-demo.md).
- **Scene sounds**: `gunshot`, `tink`, `glass`, `reload`, `dry`, `thunk` and `thud` join the scene synthesizer.

## 0.10.1 (12 November 2026)

**SDK.** No breaking changes.

- **A shoulder's caption is as large as the others**: what L, R, L2 and R2 send (a key name such as K) was printed at about half the size of a face button's caption, with room to spare. Their caption slots are now 18 units tall, like a face button's.

## 0.10.0 (12 November 2026)

**SDK.** No breaking changes. `createRoom` without `relay` now opens on the nearest relay in controller.plus's list (below).

- **A computer's QR code as a controller.plus link**: `https://controller.plus/j#v=1&local=<host>:<port>&room=…&token=…` names the computer's address in `local` (the other fields as in its local link), so a phone with the app opens it in the app and one without lands on controller.plus. `parseJoinURL` reads it as the local link it stands for (origin `http://<host>:<port>`, never controller.plus). One rule on every client: `local` is read only on `https://controller.plus/j` links, never on any other link; there it is required once, an IPv4 address or DNS host name with a port 1–65535, and anything else (IPv6, user, path, query, escapes, spaces) is refused. The browser controller joins such a link exactly as the old local link, never trusting it more: through the relay room it names on a secure page, the computer's own page when it names none, the local address on a plain page. This holds from ENTER CODE, from the in-page scanner (which shows the computer's name from the link) and for controller.plus's hand-over to `/j?browser#…`, after which the page's address becomes `/join`. `localLink()` in `web/join-code.mjs` gives the local link. Old links work as before.
- **ENTER CODE on the browser controller**: the scan screen's "NO CAMERA? PASTE A LINK" key and its link field are gone. ENTER CODE turns the LCD into six character cells for the code a Controller+ computer shows under its QR (capitals; a typed S shows as 5 and Z as 2, the characters codes have; spaces and dashes are ignored; a code with 0, O, 1, I or L is not found without asking); JOIN and BACK take the places of SCAN and REMOTE beside the LCD, above the phone's keyboard. JOIN asks `https://controller.plus/api/join-codes/<CODE>` (5 seconds at most) and joins with the computer's link exactly as its scanned QR would; the LCD says what the apps say: CODE NOT FOUND. CHECK IT ON YOUR COMPUTER., TOO MANY TRIES. WAIT A MINUTE., NO INTERNET. SCAN THE QR INSTEAD., or CAN'T CHECK THE CODE RIGHT NOW. SCAN THE QR INSTEAD. when controller.plus answers with anything else. A `join_code` usage event carries only ok, miss or limited, never the code. On a secure page (controller.plus), a computer's local link joins through the relay room the same link names, and a link without one opens the way the phone's camera opens it; scanned codes take the same path (`web/join-code.mjs`). `SessionOptions.pairingMethod` gains `'code'`.
- **Relays from controller.plus**: every relay comes from `https://controller.plus/api/relays`, so relays in other regions need no update. `createRoom` without `relay` opens on the nearest listed relay (each relay's health check timed three times, the fastest that answers wins, ties and failures go to the list's default) and keeps it for later rooms while it answers; `room.relay` names it. A relay can answer a phone's hello with `relay-moved`; `Session` follows it once when the list has that relay (`relayMove` decides otherwise). The browser controller joins a relay on another site only when the list has it, and says it is not a Controller+ code otherwise. New entry point `@controller-plus/sdk/relays` ([relays module](docs/sdk-relay-host.md#relays-module)).
- **A gamepad's shape**: the edges between the grips curve inward only a little, like a real pad's: a shallow dip along the top and a shallow arch along the bottom, on every layout and every built controller, instead of the deep dip and notch. On a tablet (any screen squarer than 16:9) the gamepad keeps a real pad's proportions: it fills the width, sits centred and leaves the glass above and below it empty, instead of stretching its grips to the screen's height. Phones keep their full-screen fit. `padScreenFit()` gives a view's fit; `screenFit()` takes an optional smallest aspect, and its result an `offset` that `padViewport()` applies.
- **Build your own controller**: a gamepad is a left part, a right part and the keys on top. Each side takes a D-pad, a stick, a stick over a D-pad, two, four, six or nine buttons, a stick with four buttons, or nothing; the keys on top are none, L and R, or L and R with L2 and R2. A view may ask for `parts: {left, right, shoulders}` (with `names` and `colors` for single buttons); `partsView()` fills the fields older phones read, so they show the nearest built-in layout. Buttons get gamepad buttons by default (face buttons first, then what the body lacks); the rest travel as a `part-keys` event. The controller reports Left side, Right side and Shoulders as settings rows. Today's four layouts are named combinations and are unchanged. Every part is drawn in every finish with 44-point targets on every screen shape (`qa/parts/CONTRACT.md`).
- **Shortcut icons on keys** (`surface-icons-2`): search, screenshot, copy, paste, cut, save, folder, windows, desktop, code, slides, a raised hand, share screen, leave call, globe, settings, trash and music. The browser controller draws them and offers the feature; hosts send them only to controllers that negotiated it, and older controllers show the key's label instead ([Surfaces](docs/sdk-surface.md)).
- **PlayStation shapes on the face buttons**: Button letters gains "Shapes (PlayStation style)". Cross, circle, square and triangle are drawn as shapes in the colour the finish uses for its letters, on the gamepad, wheel, flight stick and Remote. A view may send `labels: 'playstation'`; a controller whose letters follow the game then shows the shapes, and the letters `A`, `B`, `X`, `Y` in `faceLabels` are drawn as cross, circle, square and triangle. The option in the controller's settings report is how it says it can draw them; older controllers treat the new value as `'classic'`.

**Demo games.**

- **Car Demo, rebuilt for the first ten seconds**: hold GAS with a straight wheel and a boost pad, then a jump ramp, come up within ten seconds. A winding two-lane road repeats pads and ramps every 400 m. Gears change by themselves (− and + still shift), BOOST fires a nitro tank that pads, jumps and drifts refill, DRIFT slides, RESET returns to the road and BRAKE backs up once stopped. While the wheel is near the centre, the car follows the bends and steers jumps toward the road; the help fades as you steer and is gone once you steer firmly. The TV shows a live wheel, the pedals and one line of help; the LCD shows whether tilt reaches the game. Its world and renderer are new (`car-drive.mjs`, `car-scene.mjs`, renderer `car-3d`): the road is part of the ground mesh, chunks stream within 2.5 ms per frame, and `render()` passes a host's finished frame through instead of drawing the 3D world a second time.
- **Bumper Circuit, rebuilt as a kart race**: a twisty circuit with an S, a chicane and a hairpin replaces the oval. Hold GAS as the lights turn green for a rocket start; hold DRIFT through a bend and let go for a boost; slipstream behind a kart to fill the BOOST meter; arrows on the track boost at once. Karts are bigger, CPUs keep lanes and pass, and whoever is behind gets a little help. Each phone names its own keys (BOOST, BRAKE, DRIFT, RESET; R2 or the arrow keys elsewhere), and its LCD shows lap, place, the boost meter and one message, including TAP FOR TILT. One line of help replaces the TV's text box. `render()` passes a host's finished frame through. Gears change by themselves; X no longer holds the speed.
- **Plane Demo, rebuilt for fun**: an endless trail of rings, the first in a cloud straight ahead and passed within seconds. The plane levels itself, pulls up before the ground and rocks, and is drawn into a ring it is heading for; full tilt rolls and a full pull loops, and the game names each stunt. FIRE launches fireworks; POWER is now BOOST. A new `plane-3d` renderer builds terrain a few chunks per frame (no stalls when crossing into new land), adds woods, cumulus and wind streaks, and shows a small live picture of what the phone sends. The phone LCD counts rings and says where the next one is.
- **Sky Slalom, rebuilt**: a WebGL city at dusk (`slalom-3d`) with split screen for up to four people, a ring assist, an automatic pull-up over rooftops, solid buildings, catch-up for whoever is behind, and CPU pilots that finish their run. Keys read FIRE, BRAKE, STEADY and BOOST. The wall of help text is gone; the TV says one thing at a time.
- **Rally Court, rebuilt**: the phone is the racket. The racket on court turns exactly as the phone turns, its face picks the spot through the Racket Demo's aim, and a swing as the ball arrives hits it; your player runs for you. One swing serves and always lands in; no-ad scoring, first to three games; the bot plays kind opening shots and misses more when you are behind. People on both teams get a split screen, each behind their own player. The scene draws in about 20 calls instead of 100 to 126 ([Rally Court](docs/rally-court.md)). Games may export `interpolate(view, a, b, t, dt)`; `scene.mjs` uses it between snapshots.
- **One draw per frame for every game on a scene host**: Signal Vault's `render()` drew the whole vault again under the scene's finished frame on hosts built on `createScene` (controller.plus/play among them). It now passes that frame through, as every other game does; Midnight Table and Ink Heist do the same. A test renders each game through such a host and checks it draws once.
- **A key held at GO stays held**: every controller lets go of held keys when the view's phase changes, and the phone dropped GAS at GO just after Bumper Circuit asked players to hold it through the lights. `gamepadView()` and Orbit Crew now give the phone one phase from the 3-2-1 into play (`phonePhase()` in `common.mjs`), so GAS, Orbit Crew's stick and Sky Slalom's throttle stay held; the end of a round still releases them.
- **Breaking for code that imports it: removed `examples/games/demo-scene.mjs`**, the `vehicle-3d` renderer the Plane and Car demos shared: each now has its own (`plane-3d`, `car-3d`). Release a TV canvas with `disposePlaneRenderer` from `plane-scene.mjs` or `disposeCarRenderer` from `car-scene.mjs` instead of `disposeDemoRenderer`. `motionMessage` and `demoKeys` left `demo-common.mjs` with it, and `render.mjs` no longer has a 2D Sky Slalom (the race is drawn by `slalom-3d`).
- **Party games, redone for a room of friends**:
  - **Midnight Table**: the day is one phase. Tap a name, then POINT; your finger can move until sundown, and the big screen draws everyone's finger as an arrow with counts. When every person has pointed, an eight-second last call ends the day. Two or more fingers send the most-pointed player out, and their role card turns on the table. Nights end once everyone has chosen; dawn turns the taken player's card, and the next day shows how many kept an eye on each guest. Guests fill the table to five seats. The uncovered phone screen reads the same for every role.
  - **Ink Heist**: the artist picks one of three words. A letter appears at 35, 55 and 75 percent of the round, never more than half the word. One slip in a word of five or more letters counts; everyone's wrong guesses show on the big screen, near misses and right answers never do. The game ends on a gallery of every drawing. Every person draws at least once.
  - **Signal Vault**: digits fill the dials like a PIN. A wrong code shows which dials were right and costs five seconds. Alone, the order stays up, then reads right to left, then only flashes; together, the reader changes every lock. Players at a local keyboard or gamepad read their clues on the big screen. The LED clock is visible again.
  - All three export `lobbyView()`, which shows START without dealing a role, word or code.

## 0.9.2 (11 November 2026)

**SDK.** No breaking changes.

- Browser controller, Remote: CENTERED now shows as a solid plate on both screens whenever the phone is held upright and facing forward, with or without a game, and one small vibration confirms a steady hold. The phone drawing gives hints to get there: hold upright, or turn left or right, or tap CENTER.
- Browser controller, Remote: the drawn phone only paints the sides that face you, so its screen can no longer turn black at some angles.
- Browser controller: switching between Remote and Gamepad while settings are open rebuilds the settings with the right parts, so Get Pro stays where it belongs.

## 0.9.1 (11 November 2026)

**SDK.** No changes.

**Demo games.** Racket Demo now plays a wall rally. Hold the phone to choose a wall target, then swing to add power. The racket helps meet the ball, and the wall sends it back to the other side of the body.

- Wall hits score 1, targets score 3 and the lit target scores 5. The middle of a target doubles its points. A lit hit lights another target. RALLY, SCORE and BEST show progress without a time limit.
- The last calm aim stays with a swing, including its follow-through. Ordinary shots clear the net; clearly wrong held angles can go wide, into the net or over the wall. A held phone can block softly. Keys and sticks need a swing.
- The racket and ball move between state updates. The court draws at up to 1920 pixels wide, with a higher camera, one thin meeting ring and visible target hits.
- Low contacts get enough height to clear the net. Scoring uses the exact wall crossing. Phone readouts stay within the LCD’s character and line limits.
- Wall-rally state has TypeScript fields. Repeatable seasons, trajectory checks and headless Chrome frame checks cover the new play. The motion format and wire protocol are unchanged.

## 0.9.0 (10 November 2026)

Numbered menus make settings easier to navigate, the Remote shares one ready pose with Racket Demo, and hosts handle old and future phone versions more safely.

### Phone controllers

- **Numbered LCD menus**: settings show sections, the selected position and a position bar. Navigation wraps; touching a selected choice changes its value. Gamepad, trackpad, keyboard, deck, game screens and Remote use the same menu structure.
- **Clearer deck keys**: larger labels, separate icon and caption areas, no scanlines over key artwork, and recessed blank slots. Rows keep their available height instead of giving it to the LCD.
- **A shared Remote centre**: the CENTER lamp, ready pose and auto-centre helpers use the same rules as the iPhone and Android apps. Games can ask the player to hold the ready pose before play ([Remote](docs/remote.md)).
- **Scanner and mode notices**: the scanner explains where to point the camera, offers paste and help, and acknowledges the supplied game name before joining. Mode changes briefly name the active controller.

### Games

- **Racket Demo**: assisted positioning helps measured swings, the SWING key and still blocks meet the ball. The whole racket stays inside the court, the hand and forearm drawing are removed, and the first feed waits for the ready pose. During play, a sustained still, upright, off-heading hold brings back the centre reminder ([Racket Demo](docs/racket-demo.md)).

### For developers

- **Motion compatibility**: `MOTION_REVISION`, `motionRevision`, `normalizeMotion` and `normalizeMotionInput` identify and normalize revision-1 input. Missing revision metadata means revision 1; unsupported revisions suppress motion while keeping ordinary controls. This release does not introduce a revision-2 wire format.
- Direct Node hosts enforce `game.requires.controller` for installed apps and include the game's name in QR links. `joinURL` accepts an optional `name`.
- **Recorded compatibility checks**: conversations from earlier browser, phone and desktop releases pin handshake, update, input and motion behavior. `npm run test:compatibility`, the recording script and the [compatibility guide](docs/compatibility.md) cover replay and a future motion rollout.

## 0.8.0 (10 November 2026)

Surfaces can type live and switch screens with one key, the drawn trackpad behaves like a laptop's, and phones stop showing refusals that explain nothing.

### Phone controllers

- **Keyboards that type as you press**: `keyboard({ input: { event } })` sends each edit the moment a key is pressed (`{ deleteBefore, text }`, or `{ key }` for Enter, Tab, Escape and the arrows), in any language the composer supports; Delete repeats while held; host-provided arrow keys can repeat with `repeat: true`. Without `input`, a keyboard collects text and submits it as before ([surface](docs/sdk-surface.md)).
- **Accents**: holding a key shows its alternates as drawn keys above it; slide or tap to choose, release for the plain letter. Spoken controls open the same chooser. The chooser keeps clear of the round keys beside the LCD when a clear placement is available.
- **A second round key beside the LCD**: `lcd({ quick: { id, label, icon, event, payload } })` draws a quick key under MENU that sends an ordinary event, for a one-press switch between two screens. Its touch target is at least 44 points and it has a spoken label.
- **Trackpad gestures by one shared contract**: tap, double tap, tap then drag, hold to drag and a two-finger tap for the right button, with the same timings in the browser controller and both apps (`testing/trackpad-gestures.md`, 46 recorded sequences). Slow movement keeps its fractions and fast movement is no longer clipped. With `trackpad({ touchEvent })` the phone also reports fingers landing and lifting, so a host can stop momentum the instant a still finger touches.
- **A screen always gives way to the next one**: an error while the old screen is torn down can no longer keep the new one from showing, and a gesture in progress is ended before a switch is requested.
- **Refusals that say something**: a refusal the phone knows keeps the phone's own words and next step; one it has no words for is shown in the host's own words when they are valid notice text instead of an empty line, logged once per cause. Connected to a computer, the wording says "computer", not "game".

### For developers

- `hello.features` / `welcome.features` negotiate `surface-quick` and `surface-keyboard-live`; a host sends the new fields only to phones that advertise them, and older phones keep the collect-and-submit keyboard.
- The browser controller paces key, text and deck events for hosts that advertise no higher `eventRate`, and no longer sends `controller-mode` to a desktop host.
- Example hosts take their origin from the port they were given.

## 0.7.1 (10 November 2026)

Fixes from independent audits of a developer's first hour with the package, page load and the relay.

### Phone controllers

- **A plain Remote view reports the hand**: `controller-mode` (with `hand`) is also sent for a dedicated `kind: 'remote'` view, on join, rejoin and when the player changes Hand. Before, only views with a `modes` list reported it.
- **Faster start**: `web/controller.html` lists the controller's whole module graph as preloads, so a phone fetches its modules together instead of one import level per network round trip (`scripts/build-preloads.mjs` rebuilds the list; a test fails when it is stale).

### For developers

- **Strict TypeScript**: `createRoom({ RTCPeerConnectionImpl })` accepts the native peer class; the root declarations export the hand helpers; `fromGamepad` accepts a Gamepad-like `{ axes, buttons }`. A test compares every entry point's runtime exports with its declarations; two internal values (`feedbackResult`, the test driver's `TestPage` class) are no longer exported at runtime.
- **Testing helper**: `press`, `stick` and `slide` wait until a control holds still, and `setSetting` waits for the game's view to settle, so a touch is not cancelled by a layout refresh that follows a setting change.
- **Relay limits** ([protocol](docs/protocol.md#host-specific-budgets)): frames are bounded by structure as well as size, each connection has a byte budget, a room's public state is broadcast at most 20 times a second, and connections and rooms are capped per network address. Honest games stay far inside them.
- The shipped hand test runs from an installed package, and the protocol reference states the current version.

## 0.7.0 (9 November 2026)

Your hand moves with the racket: Remote games get an estimated hand position, and the phone says which hand holds it.

### Phone controllers

- **Hand position for Remote games**: `createRemoteHand`, `updateRemoteHand` and `centerRemoteHand` (`controller-plus/remote`) estimate the shoulder, elbow, wrist and phone from the Remote's orientation with a Daydream-style arm model, then add the part of a swing the accelerometer measures beyond the arm, settling back to the arm when the phone is still. The state is plain JSON ([remote](docs/remote.md)).
- **The phone says which hand holds the Remote**: `controller-mode` may carry `hand: 'left' | 'right'` in Remote mode, sent again when the Hand setting changes; the bundled bindings pass it to games as `setMode(id, mode, {hand})`. Older phones omit it, which means right ([protocol](docs/protocol.md)).
- **Heading**: tilt never drifts and CENTER resets heading on every platform; the iPhone app now uses Apple's compass-corrected frame for steadier long-term heading.

### Games

- **Racket Demo**: your hand and forearm follow the racket, so forehands on your side, backhands across your body, and high and low balls all work by swinging. The ball machine alternates FOREHAND and BACKHAND; shot speed comes from real-scale racket kinematics (a relaxed swing about 45–55 km/h, a hard one over 100); a racket held still blocks; the TV reads Lean, Tilt and Face; left-handed players get a mirrored arm.

## 0.6.0 (8 November 2026)

From a playtest with the phone in hand: steady Remote screens, games you play by moving, and game screens drawn one way on every phone.

### Phone controllers

- **Steady X/Y/Z labels**: the 3D view's axis letters follow their tips smoothly and fade when an axis points at you; they never jump between spots.
- **The primary key under the thumb**: the Remote's first button (Swing, Serve) is the large key at the lower part of the deck on the holding hand's side; the second sits above it.
- **Game screens are landscape on every phone**: drawing, guessing, votes, roles and keypads use their landscape layout whatever the phone's orientation or rotation lock, rotated on a portrait phone like the gamepad, with touches mapped through and keys at real sizes.
- **Game rumble and game sounds are on by default.** Views may declare `feedback: ['rumble', 'sound']` (the bundled bindings add it from a game's features); a phone with one of them off shows a short LCD notice when the game starts, or on the first cue from an older game ([feedback](docs/feedback.md)).

### Games

- **Racket Demo**: the phone is the racket's handle (top edge to the head, screen as the strings) using the Remote's own orientation; the TV and phone show how to hold it. You hit by swinging, no button: the racket face's swept path decides contact, and the face angle and head speed decide the shot (lob, drive, cross-court, backhand), shown with its name and speed.
- **Plane Demo**: real aerobatics (rolls, loops, inverted flight; STEADY levels), flares launched from the nose along the flight path, solid ground, water and rocks with bounces, scrapes and rumble.
- **Car Demo**: engine, shift, boost, tyre, sand and impact sounds; GEAR UP / GEAR DN keys and a gear display; solid rocks and cacti.
- **Gamepad Demo**: the character faces where it moves after spinning.

## 0.5.1 (8 November 2026)

- **One Remote face**: the browser controller's face is now the exact reference the iPhone and Android apps match: the sculpted shell, deck, keys and screens line up within a fraction of a pixel. Face buttons keep their portrait size in landscape.
- **Motion off, blocked or stopped** looks the same on every page: PHONE 3D keeps its title with an aim marker you can drag and the next step at the lower left; the graph pages keep their X/Y/Z columns with `--` and the next step right below.

## 0.5.0 (8 November 2026)

Four controller playgrounds lead the demo games, the Remote becomes a 1:1 motion controller with a 3D view and X/Y/Z graphs, and game bindings follow each player's controller mode. 0.4.0 phones, games and hosts keep working.

### Phone controllers

- **Remote, like a VR hand controller**: a live 3D phone that turns 1:1 with yours, and rolling X/Y/Z graphs of turn speed (degrees per second) and acceleration (g); VIEW flips between them. **CENTER** is on the face in every state (tap, or hold for half a second) and now also works with the phone held upright: the heading comes from whichever of the top edge or the back lies flatter, and gravity stays down. Six shared CENTER vectors in `testing/motion-vectors`. MOTION shows gold only while live samples arrive. The same face (sculpted shell, two olive LCDs, CENTER / VIEW / MOTION / MENU) is drawn by the browser controller and the apps.
- A fresh join shows the real motion state (MOTION OFF, tap MOTION to turn on), never "paused"; a blocked MOTION key opens browser help with RETRY.
- **controller-mode**: the browser controller (and the 1.8.0 apps) tell the host when the player picks another listed mode in MENU, and again after joining ([input mappings](docs/input-api.md)).

### Games

- **Racket Demo** ([guide](docs/racket-demo.md)): your phone is the racket. The TV shows live tilt, swing speed and held keys; a ball machine feeds practice balls.
- **Plane Demo** and **Car Demo** ([guide](docs/free-roam-demos.md)): free flight over an endless landscape and a drive across an endless desert, with live input and calibration help. Plane's wing-levelling key is STEADY, so only the small tilt key is called LEVEL.
- **Gamepad Demo** ([guide](docs/gamepad-demo.md)): a 3D island for up to four players where every button, stick and trigger does something visible.
- **Rally Court**: the standard `connect` binding; articulated players with run and swing poses, a seated crowd and new scenery; short prompts that name the phone's keys; a full gamepad view and gamepad help for a phone in Gamepad mode; a hit sound on the phone; How to play behind an optional action that hosts can forward (`pointer(x, y)`, `key(event)` on the renderer and the shared scene).
- Bindings pass `mode`, `source` and `motion` to views; `connect(host, game, {modes})` and `binding.setMode(playerId, mode)`. Every game's views carry `phase`.
- Plain words in every game's help, and each mode's instructions name only that mode's keys.

## 0.4.0 (8 November 2026)

The Remote, Rally Court, seamless network switching, public host hooks and a browser controller that looks like a controller in every state. New messages are used only when both sides support them, so 0.3.0 phones, games and hosts keep working.

### Phone controllers

- **Remote**: a portrait motion controller for one hand (left or right, one or two named buttons, an optional stick, CENTER and MENU), an aim pointer on axes 2/3, swings and flicks with a touch fallback. Shared view and event validation, TypeScript types, developer helpers and portable motion test vectors; `modes` and `motion` can suggest Remote.
- **Everything looks like a controller**: every phone state reads on the LCD with a short code from one 45-code table ([status codes](docs/status-codes.md)); a red DISCONNECT key appears when the game stops responding; help, Report a problem and Connection details are controller panels with 100 timestamped connection steps and an optional support email from the host.
- **Private screens** cover secrets, release held controls and refuse actions while the phone is offline or the game is away, and come back as they were with a fresh view.
- **Older private views** (`choices`, `secret-role`, `drawing`, `keypad`) are drawn with the same LCDs and physical keys as surfaces, with their wire contracts unchanged: event names up to 48 characters, large palettes paged with Clear on every page, and the palette's own CSS colour in strokes.
- **Games pick their controller**: a game's `modes` switch the phone to its mode (Gamepad, Wheel, Flight or Remote) by itself.
- Long names wrap inside keys and LCDs keep letter proportions in portrait; L and R sit behind the shell, as in the apps.
- **J5** now says: ask the person running the game to remove a phone, or try again later (a phone that leaves keeps its seat for five minutes).

### Connections

- **Seamless network switching**: the phone moves to the best path by itself without a visible reconnect; games see each phone's route, network and ping ([connection quality](docs/connection-quality.md)), and a reserved drop is told apart from leaving.
- **Backpressure** delays and never drops views, removals, releases or pongs; held input comes back after a stall; refused sends keep ownership and are retried in order; a queue drains its accepted work before refusing new work.
- **Local gamepads** keep their seat for five minutes after they are unplugged.

### Hosts and games

- **Public host hooks** ([relay host](docs/sdk-relay-host.md)): signal and input filters, peer contexts, `reconnect` and `active-link` events, `isActive`, relay input, `onInput(bytes, { reliable })`, `stopFeedback`, explicit room and seat lifecycle states, and the `@controller-plus/sdk/host-tools` entry.
- **Rally Court**: 3D tennis with the Remote, solo against a bot (easy, normal, hard), 1 v 1 and doubles ([guide](docs/rally-court.md)); `tennis.resetInput(game, id)` lets a reloaded phone swing at once.
- **Six demo games** with playtest fixes, rumble and stated modes.
- **Engines**: the C library, Godot, Python, Unity and Unreal carry this release's backpressure, stall recovery and wire checks.

### Docs

- Start pages for where the game runs (browser and Phaser, Node, Godot, Unity, Python), a ship-a-game guide, Rally Court and example game modules; every page checked against the code and its examples run.

## 0.3.0 (6 November 2026)

Everything the ten test games asked for, checked by the games that asked (all ship as is). New messages are used only when both sides support them, so phones, games, the relay and engines from 0.2.x keep working unchanged.

### Phone controllers

- **Compact gamepad**: `layout: 'compact'` with `move: 'stick' | 'dpad'` and one to four named buttons (`buttons: [{ id: 'face.south', label: 'Dash' }]`), MENU, and START when `start: true`. Input is the same as the standard pad.
- **Captions**: `captions: { 'stick.left': 'Move', 'face.south': 'Jump' }` prints short names beside controls on the full and classic pads (a compact button's own name is not repeated).
- **Names**: the first time a phone joins from a QR or link without a saved name, it asks "What should the game call you?" (Play or Skip). Names are remembered and can be changed in the settings (**Change your name**); a phone that comes back, also without reloading, sees "Welcome back" in its own strip above the controller.
- **Longer text** on custom controllers: whole questions and sentence-length answers survive (LCD title, text and sub up to 80, 512 and 256 characters; key labels up to 96). Text wraps, shrinks to 60 % and only then narrows; key labels wrap onto two lines. A game that sends more than the limits gets a `surface_text_too_long` warning instead of silently cut words.
- **Badges** on short, wide keys sit at the key's right end and never cover the label.
- **Screen readers** can use custom controllers in the browser, including live LCD tips, flashes and the countdown; secret text says Reveal secret / Hide secret.
- **Status light and signal dots**: the light on the LCD's border is green when connected, amber while connecting or when slow, red when the connection is lost and dark outside a game. Three dots on the other border show how good the connection is (orange on mobile data); the mobile-data bars no longer sit in the screen.
- **Menus**: the controller's menus read the D-pad in four directions, and a thumb rocking up and down never changes a setting (it used to cross left or right).
- **Face letters from the game win**: `faceLabels` (a desktop app that swaps A and B, for example) now show even when the player picked their own lettering, because they say what each button sends.

### Games

- **Fair timing**: phones stamp each input with the touch's own time; hosts give `input` events a `time` on the host clock and `clock(playerId)` (offset, jitter). See the rhythm recipe and `examples/rhythm-timing`.
- **`patchSurface(playerId, patch)`** updates an LCD's title, text, sub, meter or flash, or a key's label, badge, colour or state, without resending the controller (coalesced, saved for phones that come back).
- **Tilt state**: `status` events with `motion` (`on`, `off`, `needs-permission`, `denied`, `unavailable`, and whether samples arrive).
- **View receipts**: give a view an `id`; `view-result` says it was shown (or its fallback, or not supported).
- **`host.qrText()`** draws the join QR in a terminal.
- **Engines**: the same in C (`tr_command_patch_surface`, new `tr_decode_event` types, input times and the clock), Godot (`patch_surface`, `status`, `view_result`, input times), Python and Unity/Unreal (source only).
- **Python**: a ctypes package over the native library with a host connection, and a pygame starter.

### Testing

- `openPhone(url, { askName: true })` shows the real name prompt; names edited in a test survive reloads and reconnects.

## 0.2.3 (6 November 2026)

- A phone that opens a game on a home network address over plain HTTP joins again. The optional usage counter used `crypto.randomUUID`, which browsers offer only on secure pages, and stopped the first join; it now uses `crypto.getRandomValues` and can never interrupt joining. This affected browser phones joining the desktop app from its QR and `ControllerHost` games on a LAN since usage counts were added on 5 November.

## 0.2.2 (6 November 2026)

The ten test games were moved to 0.2.1 and every problem they had reported was checked again: none of the fixes failed. This release fixes what they found next, and what four code reviews found.

### Hosts

- The last `invitation` event always admits phones, even when a `removed` listener removes another phone.
- Feedback calls return `false` when the request was dropped (a closing or backed-up connection).
- A phone removed inside a `join` listener is no longer announced to `connected` listeners afterwards.
- On the relay, a seat that expires five minutes after its phone left now reaches the game as `removed` with `reason: 'expired'` (a relay fix, live on controller.plus). A view that finishes after its phone was removed is not kept.
- Types: per-platform app requirements (`{ controller: { ios, android } }`) and `SDK_VERSION`.

### Phone controller

- A page that embeds the controller renderer without the controller's stylesheet paints again (0.2.1 waited forever for a font it never loaded).
- Closing the settings sends the flight throttle again instead of leaving the game at zero.
- A local message (an error, a permission notice) shows over a game's readout until it clears; screen readers can read the readout.
- The next app versions (iOS 1.5.0, Android 1.5.1): long connection names and 20-character readouts shrink or narrow to fit instead of being cut; a game's flight attitude moves the iOS horizon (it showed only sky).

### Testing

- `release()` with nothing held does nothing; `release(id)` lifts that finger when several are down.
- `openPage()` returns once the page has loaded.
- `slide(id, value)` sets exact throttle and pedal values; controls describe their value track.
- `disconnect()` and `reconnect()` drop and restore a phone's connection while keeping its tab and held fingers.
- `openPhone(url, { name })`, `setSetting()`, `orientation()`; `send()`, `evaluate()` and `control()` are documented and typed.
- `npm test` runs one test file at a time, so browser tests never start several Chromes.

### Engines

- Godot: `instruments(player_id, patch)` (validated, merged into the saved view, at most 20 updates a second, the last always arrives). The add-on's version matches the SDK.
- C: `tr_command_instruments`, `tr_decode_event` (input, leave, invitation, player events and feedback receipts), press counters that never miss a tap between two frames, and an optional shared library for FFI (ctypes, Zig, Rust).
- Unity and Unreal: readout helpers (not compiled here: no editors installed).

### Docs and examples

- Guides send views from `join` (new and returning phones), say that a full view replaces readouts, list `RelayRoom.feedback` options, show which fields each built-in mode displays, separate browser and app Flight settings, put the HTTPS note for motion beside the first LAN address, and map the local host and relay methods side by side.
- The Flight example keeps STALL when a phone comes back; the wheel example updates readouts with `host.instruments`; example helpers close what they started when setup fails.

## 0.2.1 (6 November 2026)

Fixes from a visual check of the phone controller at eight phone and tablet sizes (352 combinations) and two code reviews:

- The wheel stays on screen at full lock on smaller phones, and its paddle clears the screen above it.
- Tablets held upright show the controller turned, as phones do.
- MENU no longer takes SELECT and START taps; a stick click is a tap on the stick; touch areas use the free space without overlapping.
- Paddles show their icon and name; small print is larger and darker; the pixel font is ready before the first paint.
- Choosing Flight in the settings no longer sends throttle.
- Game readouts: twenty characters fit on the gamepad's small screen; readout updates no longer reset the controller's message line; views with instrument values the controllers ignore keep working.
- A game host's invalid command is answered with an error instead of dropping its connection.
- After a game reconnects to the relay, saved views go only to players still in the room.
- Connection labels in plain words: Same Wi-Fi, Direct, Via server, Nearby server, Pro server, Game server.

## 0.2.0 (6 November 2026)

Ten developers built games with 0.1.0, each with a different framework, and reported what got in their way. This release fixes what they found.

### Players coming and going

- `ControllerHost` and `RelayRoom` emit the same events: `join` (with `resumed: true` when a phone comes back to its seat), `leave` (the seat is kept for five minutes), `removed` (`reason: 'removed'` or `'expired'`) and, on `ControllerHost`, `invitation` when the join link changes. `connected` and `disconnected` still work.
- `join` fires once the phone is fully seated, so `setView`, `playFeedback` and `rumble` work inside the listener (no more `setImmediate`).
- A game engine that connects late no longer sees phones that left as players, and removing a phone tells engines it left.
- A listener that throws no longer disconnects a phone; its error goes to `host.on('error')` or the console.
- Godot, C, Unity and Unreal have the same events, a roster, `remove` and invitation updates. The C hub reuses old device slots instead of running out after 32 players.

### Feedback

- `feedback-result` events: what the phone did with a cue or rumble sent with an `id` (`played`, `fallback`, `unavailable`, `rate_limited`).
- `ControllerHost` feedback calls return `true` when the request reached a connected phone. Relay rooms accept an `id` too.

### Game readouts

- Games can write up to three lines on the wheel, flight stick and gamepad screens (`instruments.lcd`) and drive the flight instrument with the aircraft's real attitude (`instruments.attitude`).
- `host.instruments(playerId, patch)` and `room.instruments(playerId, patch)` update them cheaply, at most 20 times a second.

### Testing

- `@controller-plus/sdk/testing`: test a game with simulated phones in headless Chrome, with real touches, isolated phones, rotation, reloads, feedback observation and your game's own page. See `docs/testing.md`.

### Types

- TypeScript declarations for every package entry, checked in strict mode by `npm test`.

### Phone controller fixes

- Paddle keys show their names, colours and badges.
- Reloading the phone's page takes the same seat again.
- The settings tilt switch works for the wheel and the flight stick.
- A held key lets go when the game shows a new controller.
- Drawing undo and badges behave the same in the browser, iOS and Android.

## 0.1.0

First release.
