Repository navigation
Conversation
…the title runs XCL_PRESS_AT needs every press timed before the run starts. A title's first-boot screens, legal pages with a countdown and loading screens come at different times from run to run, so a script or an agent walking them needs to decide the next press after it has seen the last screen, and a process in the background often cannot give the XCL window the focus that the keyboard path needs. With XCL_PRESS_LIVE=<file>, a thread follows the file and every complete line appended is pressed in order: a button name of XCL_PRESS_AT (case does not matter), several joined by + to be held together, an optional hold in ms (200 by default), or wait:<ms>. 150 ms of nothing follow each line so the same button twice is two presses. Lines already in the file at the start are not pressed; a line with a name it does not know is logged and skipped. The buttons are or-ed into scripted(), so they need no focus. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
The lowered program is missing an expected group barrier (or emits one where none is expected). Needs a fix before merge. — Devin |
bmjask
left a comment
There was a problem hiding this comment.
This is not merge-ready. follow() rereads the entire file every 100 ms rather than reading from offset, making a long-lived append-only automation file O(total size) per poll with repeated full allocations. Truncate-and-rewrite/atomic replacement can also be missed if the file regrows beyond offset before polling; document append-only semantics or robustly identify rotation. Finally, Queue::held advances through all expired lines with the same now, so a long inter-poll interval drops queued presses despite the comment that late polling still sees every press. Decide/test that contract, and provide current Windows/title-driven XCL_PRESS_LIVE evidence.
…t look Review: the file was read whole every 100 ms. follow() now seeks to the offset already read and reads only the new bytes; an incomplete last line is kept for the next look (complete_lines). Emptying the file, or replacing it with a shorter one, starts over from its beginning; the append-only contract and the case of a longer replacement are written in the doc. A button press held 0 ms is refused (the title could never see it). Tests: polls_far_apart_lose_no_press (three presses, polls 10 s apart: each is seen, in order; a line's hold starts at the first poll after it is due), lines_are_taken_only_once_complete. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks both. Updated in
@DavidM1911: AI-assisted (Claude Code); every result above is from this machine. |
|
Re-verification on RTX 3060 Ti (Windows 11), new head merged with current
Thanks! — Devin |
luckyteagirl
left a comment
There was a problem hiding this comment.
gameinput.rs:344–349,415–416: the watcher takes its initial file length only when QUEUE is first accessed, and that happens inside scripted() on the first GameInput state poll (line 263). The documented contract says lines already present at startup are skipped and lines appended while the title runs are pressed. With an empty precreated file, launch the title, append A\n during startup before its first state poll, then let it poll: QUEUE initializes with length 2 and starts follow at EOF, silently discarding that command. This gap can be long on a title that delays its first input query, and the late-poll queue test cannot cover it because that test starts after watcher initialization.
Could the initial offset/watcher be established at host or title startup, before GameInput polling, and could a fixture append between startup and first poll? If first-poll initialization is intentional, the docs and a ready signal need to make that boundary explicit for automation clients. Source review at exact head d0a127e662b8055cfb8f11f7e899546b7d09a829; I have not run a title-timed reproduction. AI-assisted review with Codex.
…le runs (port upstream xcl-dev#2449)
|
I tested I also ran the GTA VI menu sequence twice on an RTX 3080 using local build The first run later faulted during loading. The second reached its scheduled 300-second exit. Neither showed a playable scene. I used Codex GPT-6.2 Sol for the callback fixture and title runs. A separate Codex GPT-6.2 Sol agent verified the recorded transitions and loading observations. Codex GPT-6.2 Astra wrote this comment. I reviewed and approved this comment before posting. |
XCL_PRESS_LIVE=<file>: lines appended to the file while the title runs are pressed in order, one after another. A script or an agent can then walk a title's menus by deciding each press after it has seen the last screen. Until now every press had to be timed before the run (XCL_PRESS_AT) or made through the keyboard, which needs the window's focus.What is in it
hle/gameinput.rs: alivemodule. A thread reads what is appended to the file every 100 ms. Each complete line is queued; lines already in the file at the start are not pressed.BUTTON[+BUTTON…][:ms], names as inXCL_PRESS_AT(case does not matter), held 200 ms unless a time is given;wait:msholds nothing.scripted(), the pathXCL_PRESS_ATalready uses, so they need no focus.follow()reads only the bytes appended since its last look. Emptying the file (or replacing it with a shorter one) starts over; the append-only contract is in the doc.Why: from a background process,
SetForegroundWindow/SendInputare often refused (no focus, a system dialog on top). Screens such as first boot, legal pages with a countdown, and loading screens come at different times from run to run, so fixedXCL_PRESS_ATtimings drift.Tested
RTX 3060 12 GB (driver 610.88, 32-lane), Ryzen 7 5700X, 16 GB RAM, Windows 11 26300, Rust 1.100.0, debug and release.
cargo test --workspace --no-fail-fast -- --test-threads=4atd0a127e: 1292 passed, 1 failed, 46 ignored.gpu::recomp::lower_dxil::tests::a_bridged_mask_write_where_one_half_is_elsewhere_meets_no_barrier. It fails the same way onmainat50a9fdeon this card, and is not touched here.tests/e2e.rsneedscargo build --workspacefirst; with it, 3 passed.In the game at this head (
d0a127e): on the profile screen, with no focus,BogusthenAwere written to the file. The log shows:XCL_PRESS_LIVE "Bogus" not understood …;XCL_PRESS_LIVE "A" pressed;gamepad buttons 0x4 pressed for the first time, 13 ms later.The title then left its profile screen for its intro (checked on a screenshot before and after, not attached).
An earlier form of the same code (same module, on D3D12.X: integration branch that reaches the in-world HUD on NVIDIA (reference, not for merge) #2057's branch) drove 3 runs of the newer retail title from a fresh data folder: profile, first-boot screens, legal pages, policy checkboxes, into loading. The log shows
GameInput: live press …for each line, and the screens advance as pressed. These presses were made without the window's focus;SendInputhad been refused.Regression run
main:
PR:
(
mainran first, with colder caches; neither run reaches the code, which only acts withXCL_PRESS_LIVEset.)Not tested
XCL_PRESS_AT).AI use
🤖 Generated with Claude Code