upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/shims/gameinput_script.h
AgeCommit message (Collapse)Author
9 daysgameinput: boot.ps1 names the :hold form; rewrap the script header commentklikso
Review follow-up (MoonEyes): the InputScript help in boot.ps1 now says each press is held 300 ms and that button@seconds:hold holds it longer. The header comment in gameinput_script.h is wrapped at 120 like the rest of the file. Comments only; no code change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
9 daysgameinput: a scripted press can be held longer (button@seconds:hold)klikso
At world-start frame rates the retail title reads its pad every few seconds, so a 0.3 s scripted press falls between two reads and never arrives. An entry may now give its own hold time; without one the press stays 0.3 s. Holds of 0 or less, over 600 s or that are not a number reject the entry. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
10 daysRT-INPUT-SCRIPT-NO-SDL3: serve LEONIDA_INPUT_SCRIPT without SDL3Jan Trencansky
A build without SDL3 answered GameInputCreate with no devices and E_NOTIMPL for every other slot, so the title waited at its first "press A" prompt forever: no CI artifact or offline build could get past it. With LEONIDA_INPUT_SCRIPT set, gameinput_no_sdl.cpp now serves one scripted pad (an Xbox One gamepad) driven by the script alone: device enumeration through RegisterDeviceCallback (blocking, async, dispatcher), FindDeviceFromId, and GetCurrentReading/GetNextReading/GetPreviousReading whose gamepad and UI navigation state follow the script. Readings are taken when the title asks, so no thread polls. Without the variable it behaves as before. The parser, the 300 ms timeline, the button names, the press log lines and the UI navigation mapping move from gameinput.cpp into gameinput_script.h, which both shims use; nothing in it needs SDL. gameinput.cpp checks the shared SDL button numbers against SDL_GamepadButton at compile time. gameinput_no_sdl_test --input-script (CTest gameinput_no_sdl_script) checks the scripted pad on a fake clock. Docs: runtime/README.md, docs/gameinput.md, docs/linux_proton.md, docs/README.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>