Skip to content

Give each game started from ES-DE its own power and autotune - #187

Closed
anaveto wants to merge 2 commits into
IHulkSmashI:mainfrom
anaveto:esde-per-game
Closed

anaveto wants to merge 2 commits into
IHulkSmashI:mainfrom
anaveto:esde-per-game

Conversation

@anaveto

@anaveto anaveto commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Problem:

  • Steam sees only the emulator frontend.
  • Each ROM that ES-DE starts runs as the ES-DE shortcut. Thus, an NES game, a PS3 game and a Switch game use one limit.
  • The ES-DE shortcut has no launch wrapper. Thus, autotune receives no frame rate ("no frame rate from after 30 s" in each session).

Change:

  • Running game: the custom event scripts of ES-DE tell ClawDeck which game starts and which game stops (frontend.py).
  • Power for each game: ClawDeck keeps each game under <ES-DE appid>#<system>/<ROM>, with a power pick and autotune data for that game.
    • A game without a power pick starts at the ES-DE power pick. The game never uses the autotune data of ES-DE.
    • The ES-DE menus keep the ES-DE power pick.
  • No timer: while a game runs, the plugin watches the event file with inotify. The plugin wakes only when the script writes.
  • Setup: Fixes has an ES-DE section, also in the side panel. The setup:
    • installs the scripts;
    • sets the custom event scripts setting of ES-DE, only while ES-DE is closed (ES-DE writes the settings when ES-DE stops);
    • adds the ClawDeck launch wrapper to the launch options of ES-DE, so that each emulator writes a MangoHud log.
  • Remove deletes the scripts.
  • A game from ES-DE has no launch file of its own: ES-DE starts the game. At each start, the launch file update now skips these games. Before, each start logged "launch file not rewritten: appid must be numeric" for each such game.

Test results: Claw 8 EX (MS-1T91), Bazzite 45.20261112, kernel 7.3.3-ogc1.1.fc45, EmuDeck ES-DE, in a combined local build. This branch alone did not run on hardware.

  • Setup: the scripts are in place, the ES-DE setting is on, and the launch options of the shortcut contain the wrapper.
  • The inotify watch woke for the write of the script and not for other files.
  • Midnight Club: Los Angeles (PS3, RPCS3) from ES-DE: ClawDeck changed to the key 3119184808#ps3/Midnight Club Los Angeles at the game start, and autotune used the frame rate of the emulator.
  • The tests run the real script in the same way as ES-DE: power picks for each game, the power pick of the menus, events from before the game start, removal.
  • A test shows that a game from ES-DE gets no launch file. The test fails without the change.
  • On the Claw, the plugin logged "launch file not rewritten: appid must be numeric" 4 times on 2026-11-14 before the fix, and 0 times after the installation of the fix (13:55).
  • pytest on Linux (on the Claw, Python 3.15.2), this branch alone on main: 270 passed.
  • Rollup build and typecheck: pass.

🤖 Generated with Claude Code (model: Claude Opus 5.5, effort: xhigh)

Steam only sees an emulator frontend: every ROM started from ES-DE runs
as ES-DE's shortcut, so an NES game, a PS3 game and a Switch game all
shared one limit, and without the launch wrapper on that shortcut
Autotune had no frame rate.

ES-DE's custom event scripts now tell ClawDeck which game starts and
ends (frontend.py). Each game is kept under
"<ES-DE appid>#<system>/<ROM>" with its own pick and learning; a game
without its own pick starts at ES-DE's, never with ES-DE's learning,
and ES-DE's menus keep ES-DE's pick. The plugin watches the event file
with inotify only while a game runs: no timer, it wakes when the script
writes.

Fixes has an ES-DE section (in the side panel too) that sets it up: the
scripts, ES-DE's custom-event-scripts setting (only while ES-DE is
closed, since it writes its settings when it quits), and ClawDeck's
launch wrapper in ES-DE's launch options, so every emulator writes a
MangoHud log. Remove takes the scripts out again.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@anaveto
anaveto marked this pull request as ready for review November 14, 2026 12:35
@anaveto
anaveto marked this pull request as draft November 14, 2026 12:47
At each start ClawDeck rewrites every saved game's launch file. A game
ES-DE started is saved as "<ES-DE appid>#<system>/<ROM>" and launches
as ES-DE, so it has none: each start logged "launch file not
rewritten: appid must be numeric" for every such game. The start-up
pass is now a method (_refresh_game_launches) and skips them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@IHulkSmashI

Copy link
Copy Markdown
Owner

Merged through #190 together with the others (your commits, rebased onto main, conflicts between the fan PRs resolved by keeping both sides) and released in beta 17. Thanks a lot for all of this, it's a huge batch of real fixes! #179 is still open since it's marked draft.

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