doc(lines: { string }) → string
| arg | type | description |
|---|
| lines | { string } | |
cached(key: string, make: () → void
| arg | type | description |
|---|
| key | string | |
| make | ( | |
toyPlane(tilt: number?) → string
The toy airliner in plan view — moulded plastic fuselage, swept
wings, two underslung engines with fan faces, tailplane, fin, and the
wind-up key on the tail. This is the game's mark; it carries the title
card and the end card.
| arg | type | description |
|---|
| tilt | number? | Degrees to lean the whole toy by, so a card can sit it at an angle. |
examples
{ type = "svg", props = { svg = Art.toyPlane(-14) } }windKey(wound: boolean) → string
The wind-up key on its own — the mark for the wind-up phase and for
the planes-left pips.
| arg | type | description |
|---|
| wound | boolean | Whether the key is drawn wound (gold) or spent (dulled). |
examples
{ type = "svg", props = { svg = Art.windKey(true) } }skyline(flattened: number?) → string
A strip of the wooden skyline — the towers the plane is aimed at.
Give the box a wide, short size and it fills it. Towers past the
`flattened` share are drawn lying on their sides.
| arg | type | description |
|---|
| flattened | number? | How much of the strip is already knocked over, 0..1. |
examples
{ type = "svg", props = { svg = Art.skyline(0.4) } }star(earned: boolean) → string
One rating star, earned or not.
| arg | type | description |
|---|
| earned | boolean | Whether it is filled gold or left as an empty outline. |
examples
{ type = "svg", props = { svg = Art.star(true) } }part(part: string, intact: boolean) → string
The pictogram for one airframe part, drawn intact or snapped off.
| arg | type | description |
|---|
| part | string | `leftWing` / `rightWing` / `leftEngine` / `rightEngine` / `tail`. |
| intact | boolean | Whether the part is still on the plane. |
examples
{ type = "svg", props = { svg = Art.part("leftWing", false) } }trimDial(heading: number, range: number) → string
The heading trim dial for the wind-up phase: a wooden arc with the
aimed heading marked on it.
| arg | type | description |
|---|
| heading | number | Radians off downrange, positive to the right. |
| range | number | The radians the launcher allows either way. |
examples
{ type = "svg", props = { svg = Art.trimDial(0.2, 0.55) } }boostMark(on: boolean) → string
The boost mark — a chevron thruster plume.
| arg | type | description |
|---|
| on | boolean | Whether boost is being asked for right now. |
examples
{ type = "svg", props = { svg = Art.boostMark(true) } }diveMark(on: boolean) → string
The dive mark — an airbrake arrow pushed down onto its bar.
| arg | type | description |
|---|
| on | boolean | Whether dive is being asked for right now. |
examples
{ type = "svg", props = { svg = Art.diveMark(false) } }chainMark( ) → string
A chain-multiplier flame, for the chip that appears while topples
keep landing inside the chain window.
examples
{ type = "svg", props = { svg = Art.chainMark() } }caret( ) → string
The focus caret drawn beside the lit menu row.
examples
{ type = "svg", props = { svg = Art.caret() } }fallingBlock( ) → string
A block tumbling off the table — the mark on the tally's off-table row.
examples
{ type = "svg", props = { svg = Art.fallingBlock() } }toppleMark( ) → string
A tower going over — the mark on the tally's topple row.
examples
{ type = "svg", props = { svg = Art.toppleMark() } }shoveMark( ) → string
A displaced block — the mark on the tally's shoved-block row.
examples
{ type = "svg", props = { svg = Art.shoveMark() } }n2(v: number) → string
Three drawings the wind-up phase needs and the flight HUD reads back: how
far the key is wound, how the launcher is trimmed in elevation, and where
the throw as trimmed would go. Each is a picture of numbers the caller has
already worked out — the geometry arrives in the document's own units, so
the maths lives with the game rules and this file only draws.
| arg | type | description |
|---|
| v | number | |
windPips(winds: number, charge: number, overwound: boolean) → string
The three winds of the key, as a row of rings. The winds already
taken are lit, the one being taken now fills clockwise with `charge`, and
in the overwind red zone every ring turns crimson and a bar under the row
runs out with the zone. Draw it in a 3:1 box.
while `overwound`.
| arg | type | description |
|---|
| winds | number | Winds already taken, 0..3. |
| charge | number | How far through the next wind, 0..1 — or through the red zone |
| overwound | boolean | Whether the key is past its last wind and into the red zone. |
examples
{ type = "svg", props = { svg = Art.windPips(2, 0.4, false) } }elevationLadder(elevation: number, range: number) → string
The elevation ladder beside the trim dial: a rail with the horizon
marked across it, the trim lit from the horizon to where it stands, and a
pair of pointers riding at that height. Draw it in a 1:3 box.
| arg | type | description |
|---|
| elevation | number | Radians of nose-up trim, positive is up. |
| range | number | The radians the launcher allows either way. |
examples
{ type = "svg", props = { svg = Art.elevationLadder(0.2, 0.4) } }throwArc(spec: ArcSpec) → string
The throw seen from the side: the table, the standing city as a band,
and the trimmed throw arcing into it. Everything arrives in the
document's own 320x120 units, so the ballistics belong to the caller.
Draw it in a box of that ratio.
| arg | type | description |
|---|
| spec | ArcSpec | The drawn geometry — points, ground, launcher, city, stop. |
examples
{ type = "svg", props = { svg = Art.throwArc(spec) } }altTape(spec: TapeSpec) → string
The altitude tape: how high the toy is, with the standing city drawn
across the rail as the height that matters. The lit column and the
pointer take their colour from `tone`, so being inside the towers, over
them and about to belly in read apart at a glance. Draw it in a 1:3 box.
| arg | type | description |
|---|
| spec | TapeSpec | The drawn geometry — ground, fillTop, marker, band, tone. |
examples
{ type = "svg", props = { svg = Art.altTape(spec) } }