Skip to content

runtime: fast-forward toggle shortcut (TurboToggle / fast_forward_toggle_pad) + document the implicit Select chord - #318

Merged
mstan merged 1 commit into
RetroPortingToolKit:masterfrom
kerokline:feat/fast-forward-toggle
Sep 4, 2026
Merged

runtime: fast-forward toggle shortcut (TurboToggle / fast_forward_toggle_pad) + document the implicit Select chord#318
mstan merged 1 commit into
RetroPortingToolKit:masterfrom
kerokline:feat/fast-forward-toggle

Conversation

@kerokline

Copy link
Copy Markdown
Contributor

Follow-up to #307 (controller host shortcut for fast-forward). Two things a player hit on Breath of Fire III:

  1. Turbo is hold-only, so there was no way to lock fast-forward on and put the controller down.
  2. A host shortcut bound to a single trigger ("righttrigger+") never fired, because hotkey_pad_binding_down() treats any non-chord binding as an implicit Select + X and nothing told the player that.

Fast-forward toggle

  • host_keymap: new HOST_KEYMAP_TURBO_TOGGLE, [KeyMap] TurboToggle, default F9.
  • main.cpp: g_manual_turbo_latched, flipped on the key edge or by a fourth host shortcut, PSX_ASSIST_BIND_FAST_FORWARD_TOGGLE ("Fast-forward toggle", [hotkeys] fast_forward_toggle_pad, unbound by default), polled next to Rewind / Save states through the same hotkey_pad_binding_down() matcher. While latched the existing manual fast-forward block runs exactly as if Turbo were held, so the PSX_FAST_FORWARD_SPEED cap and presentation cadence are unchanged. OSD: Fast forward: 4x (locked) on, Fast forward: off when released. The hold shortcut's own edge message is suppressed while latched so the two never double-post.
  • Threaded through every settings hop (settings.toml → globals → launcher seed → LauncherSettings → back), mirroring fast_forward_pad; config_loader reads/writes [hotkeys] fast_forward_toggle_pad under the same pad_bind_value_ok bound.
  • test_rewind_toggle_combo.py guards the new sites (including that the toggle appears at every hop the hold binding does).

Implicit Select chord, documented

README now states that a controller host shortcut bound to one button or one trigger direction is a chord with Select, and that only a two-button capture replaces the implicit Select. The launcher companion (RetroPortingToolKit/recomp-ui#48) renders such bindings as select + … and adds the fourth "Fast-forward toggle" row. Without #48 this PR is still complete: the extra assist_binding_labels entry is simply drawn by the launcher's generic host-shortcut loop, and the keyboard F9 path needs no launcher support.

Verified (BoF3, RelWithDebInfo)

  • Launcher shows the fourth row; a seeded fast_forward_toggle_pad = 109 survives the launcher round-trip and is written back to settings.toml.
  • In-game F9 latches (OSD … (locked)), second F9 shows Fast forward: off.
  • python runtime/tests/test_rewind_toggle_combo.py passes.

🤖 Generated with Claude Code

…chord

Turbo (Tab / [hotkeys] fast_forward_pad) is hold-to-run only. Add a
press-to-latch twin that feeds the same manual fast-forward block:

- host_keymap: HOST_KEYMAP_TURBO_TOGGLE, [KeyMap] TurboToggle, default F9.
- main.cpp: g_manual_turbo_latched flipped by the key edge or by a fourth
  host shortcut, PSX_ASSIST_BIND_FAST_FORWARD_TOGGLE ("Fast-forward
  toggle", [hotkeys] fast_forward_toggle_pad, unbound by default), polled
  next to Rewind / Save states through hotkey_pad_binding_down(). OSD shows
  "Fast forward: Nx (locked)" / "Fast forward: off". Threaded through every
  settings hop (settings.toml -> globals -> launcher seed -> LauncherSettings
  -> back), mirroring fast_forward_pad.
- config_loader: [hotkeys] fast_forward_toggle_pad read/write.
- README: describe the toggle and state that a single-button / trigger host
  shortcut is an implicit chord with Select (hotkey_pad_binding_down), which
  the launcher now labels as "select + ..." (recomp-ui companion change).
- test_rewind_toggle_combo.py guards the new sites.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants