Screens
Puts every authored screen of *First Light: The Three Fires* on the glass and drives it. One instance, on the scene's `screens` entity; it needs nothing else on that entity.
Screens
Puts every authored screen of First Light: The Three Fires on the glass and
drives it. One instance, on the scene's screens entity; it needs nothing else
on that entity.
What it draws
| Screen | Layer | Redrawn | |
|---|---|---|---|
fl_scorch | 40 | never | a pulsing red bloom, shown while the censer burns its bearer |
fl_hud | 50 | every frame | the dawn bar, the triad and the censer |
fl_caption | 60 | when the line changes | a spoken line, as written text |
fl_card | 1000 | when the card changes | title, how-to, pause, the three endings |
They are separate screens because they change on completely different clocks: every number on the readout moves every frame, a card changes only when the player does something, and the scorch bloom never changes at all. Each is rebuilt only when its own content moves, and each can be shown and hidden without touching the others.
Three hands, one focus
A card carries an ordered ring of focusable rows (Cards.ids), and exactly one
of them is lit with an ember ring. game.input.console — activated the instant
a card goes up and released the instant the last one comes down — walks that
ring from the arrow keys, WASD, the left stick and the d-pad; confirm acts on
whatever is lit; back leaves the card. A mouse moves the focus by crossing a
row and acts by clicking it, and a finger taps the row itself. All three end at
the same onCallback id, and every id that changes the game's state does it by
calling FL.request(...) — the loop slice decides what actually happens.
The hover only moves the focus on the frame the pointer ARRIVES on a row. A pointer left resting on one would otherwise re-take the focus every frame, and a stick could never move it anywhere.
The how-to-play card is local
Every other card follows FL.state.phase. The handbill is this component's own
overlay, opened over whichever card is underneath and closed back onto it, so
it is reachable from both the title and the pause card without the loop slice
needing a phase for it.
While the clock is held
An editor pause stops update but the card on the glass is still the card the
player is looking at, so editorUpdate goes on drawing and driving it. Only
leaving play takes the game's screens down.
Scoped to this part · feeds back into the world's score.