mtkennerly / ludusavi

Backup tool for PC game saves
MIT License
2.16k stars 51 forks source link

Deck: Linux native games run from heroic not always detected (Shadow Tactics: Blades of the Shogun [gog]) #177

Closed sluedecke closed 1 year ago

sluedecke commented 1 year ago

Ludusavi version

v0.15.2

Operating system

Linux (Steam Deck)

Installation method

Other

Description

I have installed "Shadow Tactics: Blades of the Shogun" via heroic from the gog store. It is a native game and runs fine when started from "big picture" mode and stores its savefiles in:

/home/deck/.var/app/com.heroicgameslauncher.hgl/data/Daedalic Entertainment GmbH/Shadow Tactics Blades of the Shogun

The manifest has <xdgData>/Daedalic Entertainment GmbH/Shadow Tactics Blades of the Shogun/<storeUserId> as config and a subdir of this as save folder. prelude.rs correctly maps xdgData into /home/deck/.var/app/com.heroicgameslauncher.hgl/data but misses out on <storeUserId>.

Probably affected games (38 matches from manifest.yaml incl. duplicates) ``` 38 matches for "/unity3d/ZaiStudio/7SexySins//*.dat: 12101: /Steam/userdata//320140: 22682: /feral-interactive/AlienIsolation/Steam Saves (): 35038: /unity3d/League of Geeks/Armello/profiles//SavedGameState: 50091: /unity3d/Airship Syndicate/BattleChasersNightwar//saves: 62307: /unity3d/TheGameKitchen/Blasphemous/Savegames/: 62312: /unity3d/TheGameKitchen/Blasphemous/Savegames//options_settings.json: 112288: /unity3d/Fourattic/Crossing Souls//GameSave.sav: 112595: /unity3d/Tag of Joy/Crowns and Pawns//saves: 135811: /unity3d/Konfa Games/Despot's Game//profile.bin: 135816: /unity3d/Konfa Games/Despot's Game//settings.json: 209572: /unity3d/RigidCore Games/Ghostory//profile.sav: 242262: /unity3d/RainbowTrain/Hook//saveData.txt: 242306: /unity3d/Rainbow Train/Hook 2/: 287851: /feral-interactive/Life is Strange 2/SaveData/Dontnod//LIS2/Saved/SaveGames: 305551: /unity3d/Perfectly Paranormal/Manual Samuel//*.save: 315896: /vpltd/micromachines/GameDocuments/Saved Games/Codemasters/MicroMachines//.dat: 329871: /unity3d/Untame/Mushroom 11/prefs (base-64 encoded in .sg pref): 366035: /Legacy Games/Paranormal State Poison Spring Saves/Steam: 366040: /Legacy Games/Paranormal State Poison Spring Saves/Steam/profile.xml: 372025: /unity3d/Tomlab Games/Pictopix/: 393831: /Steam/userdata//487000/remote: 423550: /frictionalgames/Soma/Main/: 436463: /Daedalic Entertainment GmbH/Shadow Tactics Blades of the Shogun/: 436468: /Daedalic Entertainment GmbH/Shadow Tactics Blades of the Shogun//gameState_00: 436920: /feral-interactive/Shadow of the Tomb Raider/SaveData/: 439618: /SHENZHEN SOLITAIRE/: 545238: /feral-interactive/Total War WARHAMMER II/SaveData/Steam Saves ()/local/Warhammer2/save_games: 545243: /feral-interactive/Total War WARHAMMER II/SaveData/Steam Saves ()/scripts: 555447: /unity3d/Two Point Studios/Two Point Hospital/Cloud/: 555452: /unity3d/Two Point Studios/Two Point Hospital/Cloud//preferences.json: 565803: /Vampire_Survivors_/SaveData.sav: 568348: /Victor Vran/Victor Vran/: 575202: /WarThunder/Saves/: 579493: /WayOfThePassiveFist/autocloud//settings.sav: 579498: /WayOfThePassiveFist/autocloud//slot*.sav: 587404: /unity3d/Contingent99/Wizard of Legend/: 591995: /.config/EgoSoft/X Rebirth//save: ```

So I kindly request applying this patch which fixes this issue for "Shadow Tactics: Blades of the Shogun":

diff --git a/src/prelude.rs b/src/prelude.rs
index 1ab416b..de2daac 100644
--- a/src/prelude.rs
+++ b/src/prelude.rs
@@ -632,7 +632,8 @@ pub fn parse_paths(
             .replace(
                 "<xdgConfig>",
                 check_nonwindows_path_str(&format!("{}/../../config", &root_interpreted)),
-            ),
+            )
+               .replace("<storeUserId>", "*"),
             None,
         ));
     }

Logs

No response

mtkennerly commented 1 year ago

Good catch! Thanks for reporting this.