ludusavi icon indicating copy to clipboard operation
ludusavi copied to clipboard

Idea for virtualstore handling on Windows

Open plantroon opened this issue 1 year ago • 1 comments

There are certain games, especially older ones, that will "suffer" from not running with admin privileges on newer Windows versions (starting with Vista) and their writes, including their saves, will often get redirected into %LOCALAPPDATA%/Virtualstore.

However, PCGW does not include these locations. Would it be a good idea to somehow include this handling in ludusavi itself? Basically for every path listed on PCGW it would need to check if it exists in %LOCALAPPDATA%/Virtualstore.

An example of such game is Medal of Honor Allied Assault, which stores its saves in C:\Users\plantroon\AppData\Local\VirtualStore\Program Files\EA Games\Medal of Honor Allied Assault Warchest\main\save

A bit unrelated but I've had this question for a while and couldn't find the answer anywhere - how does <path-to-game> from PCGW get resolved?

plantroon avatar Aug 02 '22 21:08 plantroon

Thanks for suggesting this! I wasn't familiar with the VirtualStore feature, but it sounds like this is something that Ludusavi should handle.

A bit unrelated but I've had this question for a while and couldn't find the answer anywhere - how does <path-to-game> from PCGW get resolved?

  • On the wiki, the code for this is {{P|game}}
  • In the Ludusavi manifest importer script, this is mapped to <base>: https://github.com/mtkennerly/ludusavi-manifest/blob/72aca6ddb32aa5e96e5ce993445f78186436dffa/src/wiki.ts#L185-L187
  • In Ludusavi itself, <base> is interpreted as a configured root + an install subfolder: https://github.com/mtkennerly/ludusavi/blob/1f31d5691d43758156a2be29fbe14378bfdddf8d/src/prelude.rs#L372-L378

In 0.10.0 and earlier, the install subfolder has to be an exact match on the game's name or a known installDir from the manifest. In the next release, it will be allowed to be a partial match if it's close enough.

mtkennerly avatar Aug 03 '22 14:08 mtkennerly