five-on-it / apps/client/src/renderer/vehicle-gallery
apps/client/src/renderer/vehicle-gallery
The vehicle gallery (?vehicle-gallery), for checking the cars by eye: no server, no level, every vehicle class in a row on a plain floor, heading up the screen, each with a person in every seat (drawn by the riders as the game draws them, behind the glass of a closed one), its doors swinging open and shut together every few seconds (H holds them open or lets them swing), its steering wheel and front wheels turning from lock to lock as the game turns them, and its windscreen cracked by a shot from the driver's seat, as one fired in the game would leave it; the semi with its trailer behind it, on its fifth wheel. The camera starts as the game's (steep, from the south) over the middle of the row or over the class the address names (?vehicle-gallery=sedan) and goes anywhere (gallery-camera.ts: W A S D pan, the wheel zooms, the mouse orbits; 1–3 set its height, F goes back; its speed on the panel's slider, gallery-ui.ts, where a class is found by its name too).
window.__vehicleGallery() tells the end-to-end tests what is drawn: whether the models are in, the steering now, and every vehicle with its riders, its doors and how far open, how many of its parts turn as it steers, its cracks and where it stands on the page.