Expand description
App wiring: Repose platform runners plus sim and gamepad helpers.
Structs§
- Camera2d
- 2D orthographic camera. Owned by the UI (signals), copied into the
snapshot per frame.
effective_centeriscenter + offset. Canvas, GPU batch, and picks derive from these fields together. - Gamepad
Id - Opaque gamepad handle. Backend-local index, stable for the connection
lifetime. Survives across frames; invalid after
GamepadEvent::Disconnected. - Gamepad
Poller - Gamepad polling on the shared platform backend. Events feed
ReposeRuntime::handle_gamepad(UI nav) andrt.gamepads(gameplay). - Motion
Poller - Motion-sensor polling on top of the shared platform backend. Sensor nodes
are separate evdev nodes from the pad, so readings are routed back to pads
by name; feed
MotionPoller::feed_gamepadthe same eventsGamepadPollerdrains. - PadBank
- PadBridge
- PadMotion
- One pad’s motion, ready for
MotionTracker. Holds its own copy of the reading so it stays a plain value the sim can carry between frames. - Quit
- A quit request, latched so a browser shell can park instead of exiting.
- Retained
Root - Rumble
Bridge - Routes
HapticBusmotors toReposeRuntime::request_rumble. Uploads only on change and on refresh, and stops devices the bus dropped, since the bus stops mentioning a device rather than zeroing it. - Shortcut
Edges - Sim
- Fixed-step sim state. Game registers systems,
feeds wall time with
step, readsworldfor the snapshot. - SimTime
- Sim time, advanced once per fixed step.
- Sprite
Instance - One batched sprite.
uvis in atlas texels normalized to 0..1. - Staging
Enums§
Constants§
- RUMBLE_
REFRESH - Upload again once this much of
RUMBLE_UPLOAD_MShas elapsed, which keeps a held effect alive without restarting it every frame. - RUMBLE_
UPLOAD_ MS - Length of each rumble upload. The backend sends a fresh force-feedback effect per call, so uploads are spaced out rather than repeated per frame.
- TRIGGER_
HELD
Traits§
- Shell
Hooks - Per-frame hooks the game implements.
Functions§
- apply_
scheduler_ levels - game_
shortcut_ map - install_
game_ shortcuts - Compose the game map + edges handler once in the root view (mount-once under the hood: safe to call every frame on desktop, web, and Android-with-keyboard alike). One call per game; no per-key duplication at call sites.
- install_
handler_ into - Install only the action handler into long-lived
edges(tests and headless compose without a runner use this path). - install_
map - Overwrite the process-global default shortcut map (tests and headless compose without a runner use this path).
- on_
first_ user_ gesture - Run
fon the first user gesture on this page. - run_
desktop - Desktop entry point. Mounts
rootwith title and size. The root closure owns stepping and requests frames for continuity. The closure receives the live [Scheduler] each frame, whoseheld_keys/window_focused/mouse_*fields are the single polled hardware snapshot (GMLkeyboard_check/mouse_check_buttonparity). - shared_
edges - shortcut_
handler - take_
shortcut_ edges - user_
gesture_ seen - Whether a user gesture has been seen.