UI

  • Menu — A main menu in three lines, then an options screen, a confirm dialog and a HUD — one scene per screen under src/scenes/, and change<>() between them.
  • Layout — row, column, panel, center, stack/layer, spacer, plus image and progress.
  • Clay direct — The escape hatch. Clay's own macros in the same frame as rmp::ui, for anything the small API does not expose yet.
  • Settings — Checkbox, slider, dropdown, text input — and the focus/keyboard/gamepad navigation you get without writing any.
  • Inventory — grid with a column count worked out from the space available, scroll with clipping, tooltip() for what each item is -- under a resting pointer or the keyboard's focus -- and wants_pointer() keeping the game's hands off the UI's clicks.
  • Style — The two themes, the five variants, the three sizes and the transition.
  • Responsive — scale() versus current_breakpoint(), and which to reach for.
  • Overlay — overlay(): a pause menu pushed as a scene of its own, blurred, that freezes the game below; and "Really quit?" drawn by the game scene itself -- an overlay with a panel() in it, which is all a dialog is.
  • Skinned — The other way to write rmp::ui: a game's shop screen designed rather than written.
  • Dialogue — One Yarn conversation, three ways, switched while it runs: a DialogueBox (a portrait, a name plate on the frame, a voice per Speaker), a DialogueBubble over whoever speaks with its tail pointing at them, and a DialogueStage whose cast slides in and comes forward, shaken by a <<quake>>.
  • Localization — A lantern stall in English, Spanish, Japanese and German, switched while it runs: every literal its own key in resources/lang.tsv, German in a file of its own (lang/de.tsv), {placeholders}, plurals in each language's forms, a context, and a font per language -- Japanese in Jigmo (CC0), cut down to the letters the table uses -- with each language's name in the menu in a font that has its letters (Style::font).
  • Font — A menu in a font of your own: a title, its options and its credits, one scene each, every word in Hack Bold through one rmp::ui::set_font().