feat(controls): add per-control reset and confirm binding changes #2126
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/tooling
area/upscaling
beanstalk: approved
beanstalk: failed
beanstalk: needs approval
beanstalk: running
beanstalk: tested
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!2126
Loading…
Reference in a new issue
No description provided.
Delete branch "Phishinabowl/Longshot:feat/improved-control-defaults"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Controls now lets you reset a single row. The square curved-arrow button is available when the row's gamepad or keyboard bindings, or its Toggle, differ from the current defaults. The table headings sit below Layout preset and Button prompts. Resetting a row or all controls asks for confirmation. When a new input is already in use, the dialog names the affected control before reassigning it.
The grid gives Toggle and Reset a little more space after Keyboard. With a controller, Clear uses the available top face button or another free face button if Bind or Back uses it. The footer shows the assigned button, and keyboard input shows Del.
On main, open Controls → Controls and move down in Toggle from ZR toward Plus and Minus. Navigation reaches a row without a Toggle and moves focus to Keyboard. With this change, Up and Down stay in Toggle or Reset and skip unavailable cells. Left and Right change columns.
Start with
gpu/vk/vk_menu.cppfor focus and confirmation, andhost/nn_hid.cfor the effective defaults and binding updates.Testing
Tested:
42841c4dbefore rebase. Both built and passed 12 focused game-free checks each. In game, Up and Down skipped disabled cells without leaving Toggle or Reset. Cancel preserved the binding. Confirm restored the default and disabled the reset arrow.971f77f5and3cbdeef1plus the layout and fixture changes. The same navigation check missed both expected Toggle targets on main and reached both on the branch.tp_cancelsis set but unused.test_menu_keys.py, which fails on main.test_vbytes.py. Eight branch-only failures passed on retry:test_mesh_first_types.py,test_import_windows.py,test_cbuf_table_extent.py,test_dump_ssbo_read.py,test_mesh_dynamic_state.py,test_timeline_modes.py,test_capture_copy_nt.py, andtest_capture_copy_runs.py. The ninth,test_hos_ab.py, now passes after the test was updated for the appended ABI callbacks. The final Windows focused rerun passed six checks; Ruff passed for the three changed Python files.0x94d8c080.3541a0d2, rebased onto8aa74983. The Controls help and its existing translations now explain that confirming a conflict removes the previous binding. The new fixture executes the actual menu confirmation handlers for row reset, Reset All and conflicting rebind. It checks cancellation and acceptance against bindings and Toggles. A mutation that accepted Cancel failed at the expected assertion.test_pads_after_menu.pyandtest_xinput_thread.pyunused-variable failures. The translation-key check fails on the same unrelated Output resolution string on both branches. Ruff and the offline Graphics guide source check passed. The refreshed Graphics captures differ only by the version label.8aa74983and published head3541a0d2: main 813 passed, 107 failed, 18 skipped; PR 814 passed, 106 failed, 18 skipped. All 106 PR failures also occurred on main by test name, including thetest_vbytes.pytimeout.test_menu_keys.pyfailed on main and passed on the PR.Incomplete graphics settingon both8aa74983and3541a0d2. The upstream Graphics guide has empty default cells for two ReShade action rows. A local check with those cells filled reached a separate upstream DLSS/FSR visibility documentation mismatch. No website repair is included in this Controls PR. The PR's dedicated guide image and source review check passed.Linux failures reproduced on main (106)
test_appimage_player_build.py,test_bug_report_defaults.py,test_capture_read_once.py,test_capture_readback_visibility.py,test_cmpflags.py,test_compile_retry_jobs.py,test_compile_stops_on_exception.py,test_crash_dialog.py,test_crash_record.py,test_crt_options.py,test_damage_debug_menu.py,test_dev_packs.py,test_device_lost_exit.py,test_device_policy.py,test_display_startup_failure.py,test_dlss_feature_size.py,test_draw_binds.py,test_draw_stream_visibility.py,test_failed_compile_keeps_objects.py,test_finish_output.py,test_flush_nothing_held.py,test_frame_overlap.py,test_framegen_preset.py,test_fsr3fi_hud_layer.py,test_fsr_image_retirement.py,test_fsr_uniform_ownership.py,test_gpu_wait_stats.py,test_guest_imported.py,test_hdr_encode.py,test_high_fps_fixes.py,test_host_guest_writes.py,test_import_reach.py,test_input_background.py,test_intel_prepare_side_by_side.py,test_libc_hooks.py,test_lift_cache.py,test_lift_cleanup_error.py,test_linux_preflight.py,test_linux_pressure.py,test_linux_tools.py,test_linux_update.py,test_log_open_failure.py,test_low_vram_texture_mips.py,test_make_game_ngx.py,test_menu_env_overrides.py,test_menu_i18n.py,test_menu_ini_keys.py,test_menu_module_slots.py,test_menu_modules.py,test_menu_sections.py,test_menu_text_field.py,test_mesh_conv.py,test_mise_build.py,test_missing_nup.py,test_mods_list.py,test_mods_size_table.py,test_ngx_sdk.py,test_nonuniform_image_arrays.py,test_oot_shadow_fit.py,test_pass_barrier.py,test_pending_guest_import.py,test_pipeline_play_cache.py,test_pipeline_tour.py,test_pipelines_outlive_cache_format.py,test_prepare_cache_save.py,test_prepare_stall.py,test_present_ahead.py,test_present_device_loss.py,test_present_queue_default.py,test_present_source_crop.py,test_profiling_mode.py,test_program_cache_cleanup.py,test_program_cache_one_variant.py,test_prompts_size_table.py,test_psychov35_fsr3_fg.py,test_readback_timeout_source.py,test_recorder_own_idle.py,test_recorder_sync.py,test_reflex_swapchain_lifetime.py,test_renderer_new_handler.py,test_renhdrum.py,test_replay_write_order.py,test_rumble_menu.py,test_run_all_mingw.py,test_run_all_output.py,test_run_all_reap.py,test_sampler_admission.py,test_settings_table.py,test_slow_frames.py,test_song_note_cue.py,test_sparse_mirror.py,test_spirv_pack.py,test_staging_burst.py,test_submit_oom.py,test_target_reuse_memory.py,test_texel_buffer_ownership.py,test_ub_update_batch.py,test_ui_record.py,test_upscaler_round_trip.py,test_upscaler_rows.py,test_vbytes.py,test_vcore_escape.py,test_vcore_mask0.py,test_vibration_menu.py,test_vk_occlusion_queries.py,test_xinput_thread.py.Still to test:
Measurements
Verdict: Vertical input reaches the next available Toggle cell in either direction. The tested path runs in the open Controls grid. No frame-time claim is made for this menu interaction.
Setup: native LLVM-MinGW and Linux Clang game-free fixtures, same synthetic binding rows and press directions, compiled from each revision's navigation code.
8aa749833541a0d2Risks
Binding conflicts, slot swaps, layout presets, Sprint's effective defaults, Toggle persistence, and the keyboard or controller focus path can regress if both sides of the host/renderer ABI diverge. A reset can be canceled before changing bindings. Settings continue to use the existing options file. The change adds no switch and needs no save or shader-cache migration. Revert the change to restore the previous Controls behavior.
Checklist
Ready for review
main; the title is a Conventional Commit.mise run testpasses (any failure that also fails onmainis named). The equivalent strict Linux suite reported no PR-only failing tests; see Testing for the baseline exceptions.main, or Measurements says why there is nothing to measure.third_party/untouched; nothing GPL-incompatible.When it applies
mainand passes here.tests/that reads changed source is updated, not weakened.MKWVK_API_VERSIONbumped (MkwVkHostorMkwVkRendereringpu/vk/vk_api.hchanged). Version 44 preserves main's output-preview and input-recording callbacks.mainand here, for a change that shows on screen.Assisted-by:/Co-Authored-By:trailers.Ready to merge
main, measured again or a comment says why the numbers still hold.Tested in game: Tested in Controls on Windows 10 (RTX 3080, NVIDIA 621.24) and native Ubuntu (RTX 5090 Laptop GPU, Vulkan driver 0x94d8c080). Row reset, cancellation and navigation past disabled cells passed. On the final renderer update, both systems passed the spacing, controller Clear and matching footer icon checks. Linux also confirmed the keyboard Del hint.
UI-only captures of the same Controls grid at 1280×720. The bindings are synthetic.
971f77f5ddc420ceThe controller footer shows the face button assigned to Clear.
@review
Recommendation: Request changes. The Controls help still tells players that a binding cannot be moved in a case this change now permits. The new confirmation paths also need behavioral regression coverage.
Adds per-control resets, confirmation for resets and conflicting bindings, controller Clear, and navigation that skips unavailable cells. It improves the tested navigation path but adds host and menu state that needs coverage and current player guidance.
@fixwill do (2)gpu/vk/vk_menu.cpp:2854: The Controls help still says a button's only gamepad input cannot move to another row's empty Input 2, but the new confirmed rebind permits exactly that and can leave the original row unbound. Update this help and its translations to explain the confirmation and removal behavior.tests/test_menu_keys.py:477: The confirmation checks match source text rather than exercising the dialog. (more on the line)Before merging, for the author (2) (a run, a measurement or a decision; it doesn't hold the recommendation)
@fixor@rebasetry first).Checks: Failing on this head, which is behind its base, where it passes:
CI / Website build and checks (pull_request).@rebase(or@fix) brings it up to date and runs it again; not held against it.More: does it help, other systems, switches, what was read
Does it help: Yes for the tested navigation case: the PR reports 0/2 correct destinations on the base and 2/2 on the branch using the same synthetic rows. The author also reports successful in-game checks on Windows and Linux NVIDIA systems. This is not a performance change.
Other systems: The host binding changes affect keyboard, controller, Sprint, shared note and HUD bindings on Windows and Linux. The reported in-game runs cover NVIDIA systems; AMD RDNA and Steam Deck controller checks, final-head full checks, and the output-preview manual check remain outstanding.
Switches: None added, changed or removed.
Reviewed:
ddc420ce0dagainst971f77f525: Read the repository rules, PR template, standards, commit log, host binding changes and surrounding Sprint code, menu diff and relevant input handling, and changed test diffs. Skimmed translations, the screenshot manifest and guide screenshot rules. The full changed code files and all surrounding callers were not read in full; the Tooling AGENTS.md was unavailable in the adjacent checkout.; nothing run (a code review).Checked and fine:
Testing: No tests or project scripts were run during this read-only review. The PR reports focused Windows and Linux runs and identifies the remaining validation.
Overlaps and merge order: Unknown; network access was unavailable.
Automated code review by BeanBot (gpt-6.1-terra), asked for by llun. Nothing was run; a maintainer decides.
@ -433,1 +474,4 @@"vertical navigation must use the column-aware row selection")need(tick, r"while \(!control_column_enabled\(i, ccol\)\);","keyboard navigation must skip Plus and Minus Toggle cells")need(tick, r"if \(!press\[5\] && ask.choice == 1\) \{\s*if \(ask.action == ControlAction::Rebind\)",L2 (minor): The confirmation checks match source text rather than exercising the dialog. For example, they would still pass if the reset callback ran before the Cancel choice was checked. Add a game-free behavioral test that opens each confirmation, cancels and confirms it, and checks the resulting bindings and toggles.
@fix
ddc420ce0d3541a0d20cBeanBot follow-up in
3541a0d2: L1 now describes the confirmation and removal behavior in Controls help and its translations. L2 adds game-free coverage of the real reset and rebind dialog handlers, including cancellation and acceptance. L4 was addressed by rebasing onto8aa74983. Focused checks passed on Windows and Linux; remaining live preview, final CI and hardware checks are listed above.Refreshed UI-only captures following the rebase and help update. All use the same 1280×720 viewport and synthetic bindings.
8aa749833541a0d2Recommendation: Request changes. The help and confirmation tests now address the earlier findings, but the pull request is still reported as unmergeable. Final-head checks and controller validation on AMD RDNA and Steam Deck also remain outstanding.
The change adds per-control reset and confirmation for resets and conflicting bindings, and makes navigation skip unavailable cells. It improves control over bindings at the cost of additional confirmation and host–renderer coordination.
Before merging, for the author (1) (a run, a measurement or a decision; it doesn't hold the recommendation)
Since the last review (on
ddc420ce0d)Resolved: L1 (The Controls help still says a button's only gamepad input cannot move to another row's em…); L2 (The confirmation checks match source text rather than exercising the dialog. For example,…); L4 (It conflicts with its base branch: bring it up to date (
@fixor@rebasetry first).)Still open: L3 (The required final-head checks and controller runs on AMD RDNA and Steam Deck are still ou…)
Checks: Still running:
CI / Website build and checks (pull_request),PR description / Description follows the template (pull_request_target),CI / Conventional Commit title (pull_request),CI / Workflow lint (actionlint) (pull_request),Guide screenshots / Guide images and local UI source review (pull_request),Third-party parts / As their notes say (pull_request).Also noticed (1; not asked for, not blocking)
More: does it help, other systems, switches, what was read
Does it help: Yes for the tested navigation case: the supplied game-free comparison reached 2 of 2 expected destinations on the branch versus 0 of 2 on main. The author also reports successful in-game reset, cancel, navigation and Clear checks on Windows and Linux; no performance gain is claimed.
Other systems: The binding changes affect keyboard and controller input, Sprint defaults, saved options and the host–renderer interface. Windows and Linux NVIDIA play tests are reported; AMD RDNA, Steam Deck and the final-head checks remain outstanding.
Switches: None added, changed or removed.
Reviewed:
3541a0d20cagainst8aa7498345: Read AGENTS.md, CONTRIBUTING.md, the pull request template, the two follow-up commits and the relevant confirmation, help and binding changes. The full changed code files and all dependent callers were not read in full; translations, the manifest and other changed tests were skimmed. docs/review-checklist.md is absent.; nothing run (a code review).Checked and fine:
Testing: No commands that build or run project code were executed. The supplied CI checks are still running; the author reports earlier Windows and Linux checks and in-game tests.
Overlaps and merge order: Unknown; the network is closed.
Automated code review by BeanBot (gpt-6.1-terra), asked for by HumanBean. Nothing was run; a maintainer decides.
The branch moved while I worked (someone pushed
3541a0d20c), so I did it again on top of that. There is nothing for an edit to fix on this pull request. It was already up to date withmain.For the author (no edit does these)
Automated fix by BeanBot (gpt-6.1-terra), asked for by HumanBean. Nothing was run; a maintainer decides.
Live Windows output preview passed: the first 1024×576 trial expired, restored 1280×720 and released its storage; choosing Yes on the second saved 1024×576. The full strict Linux comparison found no PR-only failing tests against
8aa74983. The remaining website failure was reproduced locally on clean main as well as this branch; the dedicated guide screenshot CI passed.WIP: feat(controls): add per-control reset and confirm binding changesto feat(controls): add per-control reset and confirm binding changes