jaydenmilne / steamsync

Tool to automatically add games from the Epic Games Launcher to Steam
GNU Affero General Public License v3.0
157 stars 17 forks source link

Read and write shortcut ids to vdf to fix downloaded art #39

Closed idbrii closed 6 months ago

idbrii commented 6 months ago

Read and write shortcut ids to vdf

Fix #37: Downloaded art no longer displays in Steam.

Valve changed how Steam identifies art. Instead of hashing the exe and name, it generates a shortcut id and stores it in shortcuts.vdf as 'appid'. Presumably this is so art is preserved when renaming shortcuts.

We can't wait for steam to populate the shortcut_id for our newly added shortcuts, so instead we use the old method to generate a shortcut_id and write it into the vdf. After removing other shortcuts and multiple restarts of Steam, it seems that this method reliably and permanently sets a shortcut id.

Also use the new name format for big picture art. It now matches the id format of the others.

Test

Also adds a --dump-shortcut-vdf argument which is helpful to debug this kind of issue.

Also handles "Win10" suffix on games when detecting appid. I was testing with Death's Door and it wasn't detected correctly.

jaydenmilne commented 6 months ago

You're a hero for doing this