▣
module · drop-in viewer
What it does
controls
What the player is holding, and what it says on it.
The control table lives here as data, once, so the how-to-play card, the row hints on every menu and the pause card all read the same row and none of them can drift from the others. The device family is asked of the input layer rather than guessed, and a pad's face-button legends are resolved from the pad that is actually connected — A on an Xbox pad, Cross on a PlayStation one.
local controls = require("game.ui.controls")
controls.family() --> "kbm" | "gamepad" | "touch"
controls.hint("confirm") --> "ENTER" | "A" | "TAP"
Discussion
Scoped to this part · feeds back into the world's score.
Sign in to post.sign in
No comments yet. Be the first.