Log inGet started
World

Ironspine

Branchmain
Branchesmain
Commit9a7cce6233

README.md

ui/hud.module — the suit instrumentation

Hud.build(view) turns a snapshot into a widget tree. It is pure: it reads nothing and writes nothing. ui/screens.module owns the snapshot, the registration and the tick.

What is on the glass

  • Two grip plates, hard left and hard right, one per hand, so a glance says which hand is dying. Each carries the hand's state word, the stamina meter tinted by Game.gripColor, the measured load in newtons, that load against Game.C.gripBreakForce, and whether the boot on that side is planted. Under a third of grip the plate breathes red; under a sixth it breathes twice as fast.
  • The altitude tape, right edge: the crown at Game.C.crownHeight, the sea at zero, the last piton marked in brass, and the climber's own height called out in large numerals.
  • The wind strip, top centre: bearing, newtons, and a gust flare.
  • The run block, top left: elapsed time, pitons set, falls taken.
  • The reticle, centre, with a ring and a tag on the hold Game.pickHold would actually take — the same call the hand makes, so the highlight can never lie.
  • The beacon arc, bottom centre, while the ignition ring is charging.
  • The control prompt, which fades out over the first half-minute of a climb.
  • MENU · ESC, a real button so the engine's keyboard-shortcut plumbing reaches the pause menu.

The snapshot

{ left, right,                      -- { anchored, slipping, load, stamina01, kind, footPlanted }
  altitude, lastAnchorY, anchorsSet, falls, timeText,
  windNewtons, wind01, windDeg, gusting,
  beacon01,
  reticle = { x, y, tint, hold = { x, y, kind, grip }? },
  hintOpacity }