gameinput: preserve controller transitions between polls (OLD-9966, carries #233) #1831

Open
github-bot wants to merge 1 commit from github-bot/gh-1831 into main AGit
Owner

@⁠potatoe0100 on GitHub · 2026-11-25 12:45 UTC · original
potatoe0100:carry/old-9966 → main · +167 −75 · 3 files · 1 commits · open

Claimed in the coordination issue as: OLD-9966 (#1608)

What and why

Carries forward old-pr/9966 (draft #233) by @⁠tedin7, rebased on main 0d80bc5df with the author's commit. A press and release that both land between two polls used to be lost, because each poll only compared the latest snapshot. Pads that were already open replay their SDL button and axis events in timestamp groups, publishing one reading per group, so the title sees each transition.

Rebase notes: runtime/shims/gameinput.cpp conflicted in poll_once(), where main added the LEONIDA_INPUT_LOG press log. The branch moves reading publication into publish_pad_sample(); the press log moved there with it (before last_snap is updated), so replayed transitions are logged too.

Supersedes draft #233 (its branch can be deleted once this lands).

Tested

VS 2022 (MSVC 19.44) RelWithDebInfo + Ninja with -DLEONIDA_SDL3_FETCH=ON (so gameinput and gameinput_script are built and run, not Disabled).

  • gameinput and gameinput_script pass.
  • Full ctest -j 6: 440 of 440 passed.

GPUs tested: NVIDIA GeForce RTX 4060, driver 621.14, Windows 11 Pro 26H2 (build 26300) (no GPU-specific code here)

AI-assisted: yes (Claude Code), by a non-developer tester.

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (n/a: no translator change)

🤖 Generated with Claude Code

**@⁠potatoe0100** on GitHub · 2026-11-25 12:45 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/1831) `potatoe0100:carry/old-9966` → `main` · +167 −75 · 3 files · 1 commits · open Claimed in the coordination issue as: OLD-9966 (https://git.gtahub.st/github/ubiquitarianism--leonida/issues/1608) ### What and why Carries forward `old-pr/9966` (draft #233) by @⁠tedin7, rebased on `main` `0d80bc5df` with the author's commit. A press and release that both land between two polls used to be lost, because each poll only compared the latest snapshot. Pads that were already open replay their SDL button and axis events in timestamp groups, publishing one reading per group, so the title sees each transition. Rebase notes: `runtime/shims/gameinput.cpp` conflicted in `poll_once()`, where `main` added the `LEONIDA_INPUT_LOG` press log. The branch moves reading publication into `publish_pad_sample()`; the press log moved there with it (before `last_snap` is updated), so replayed transitions are logged too. Supersedes draft #233 (its branch can be deleted once this lands). ### Tested VS 2022 (MSVC 19.44) RelWithDebInfo + Ninja with `-DLEONIDA_SDL3_FETCH=ON` (so `gameinput` and `gameinput_script` are built and run, not Disabled). - `gameinput` and `gameinput_script` pass. - Full `ctest -j 6`: 440 of 440 passed. GPUs tested: NVIDIA GeForce RTX 4060, driver 621.14, Windows 11 Pro 26H2 (build 26300) (no GPU-specific code here) AI-assisted: yes (Claude Code), by a non-developer tester. ### Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [x] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. (n/a: no translator change) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 10:07:32 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1831/head:github-bot/gh-1831'
git switch 'github-bot/gh-1831'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1831'
git switch 'github-bot/gh-1831'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1831'
git switch 'github-bot/gh-1831'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1831'
git switch 'main'
git merge --squash 'github-bot/gh-1831'
git switch 'main'
git merge --ff-only 'github-bot/gh-1831'
git switch 'main'
git merge 'github-bot/gh-1831'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.