Repository navigation
Conversation
catminou4
left a comment
There was a problem hiding this comment.
Static review only: victory-hle is Windows-only — nothing compiles or runs on macOS; source review of the diff.
VICTORY_KEYS can hold a key longer than 0.2s — input-timing fix for diagnostics; relates to #2114's stand-in pad.
|
Windows validation on c26291a with diagnostics enabled. All 9 GameInput unit tests passed. I also ran a local probe using the production scripted-key source, a synthetic connected pad holding B in slot 1, and the GameInput current-reading interface. Each row ran in a fresh process.
The extended hold reached the consumer past the old 200 ms default, then released while preserving B. Synthetic input only. AI-assisted validation. |
|
Automated triage for the maintainers. This lets the diagnostics-only Generated by Claude Code |
|
Code review and Windows 11 verification at head
LGTM. |
|
Tried the hold syntax on the fxceless fork. With One edge case I found while adding the boundary test: checking |
The scripted keys held each key for 0.2 s with no way to change it. A screen that samples its input more slowly than that ignores the key, and the run looks exactly like a screen that ignores input - which is what cost me a morning: I concluded the setup wizard took no input at all, when the operator advanced the same screen by hand. An entry may now carry its hold: `at:key:hold`, in seconds, 0.2 when it does not. The parse is a function of its own so it can be tested; the test pins the default, an explicit hold, and a hold that does not parse (the key is kept, because the run matters more than the exact timing). No behaviour changes for an existing VICTORY_KEYS string.
…keeps the default
c26291a to
6c9548f
Compare
|
The window is what gets tested now, and the two edge cases are fixed Head
Measured here: Not verified: a run of the title with a long hold — this machine's session 0 cannot present, so the click that motivated the change has not been re-shot through the menu. Written with an AI assistant. |
VICTORY_KEYScould not hold a key for longer than 0.2 s, and that ambiguity cost me a morningThe scripted keys held every key for 0.2 s, hardcoded:
That is fine for the screens it was written for — it advanced the conditions page and the notices — but it makes one particular failure impossible to tell apart from another: a screen that samples its input slower than the hold behaves exactly like a screen that takes no input. I spent this morning concluding the second about the setup wizard, and it was wrong: the operator advanced that same screen by hand with the keyboard.
An entry may now say how long to hold it:
at:key[:hold], the hold in seconds, 0.2 s when omitted, so every existing string behaves exactly as it did. The parse moved intoparse_scripted— a function of its own, testable without touching the environment — and the test pins three things: the default, an explicit hold, and a hold that does not parse, which falls back to the default rather than dropping the key, because a run that loses one press is worse than one that presses slightly wrong.cargo test -p victory-hle --features diagnostics --lib→ 143 passed, with the one failuremainalso has in a session with no desktop; clippy with and without--all-featuresclean under-D warnings;rustfmt --checkshows the same four hunks the file already had onmain.What this does not do is prove that a longer hold gets past the wizard. That is the next run, and it will say either way — the point of the change is that the answer becomes a measurement instead of a guess. If the wizard still ignores a 0.8 s hold, then it genuinely does not take keyboard input, and the next place to look is the pad it might be waiting for, not the length of the press.
No game data is involved: an environment variable and a test.
Written with an AI assistant.