Razzmatazzz / RemnantSaveManager

Automatic backing up of your Remnant: From the Ashes save files, and the ability to anlayze your world to see what events rolled.
https://www.reddit.com/r/remnantgame/comments/d4eq86/remnant_save_manager_and_world_analyzer/
GNU General Public License v3.0
117 stars 21 forks source link

Windows Store Version Only Partially Supported #46

Open Razzmatazzz opened 3 years ago

Razzmatazzz commented 3 years ago

The Windows Store version of Remnant uses a completely different save path AND completely different save file names from the Steam/EGS versions of the game. Adding support for this version of the game would likely require a significant re-write of this app.

Path information from Flandre5carlet:

After looking up online where save games might be for Microsoft Store games, I've found the path %LocalAppData%\Packages in a Microsoft Forums thread.

Indeed in the following path: C:\Users\[USERNAME]\AppData\Local\Packages\PerfectWorldEntertainment.RemnantFromtheAshes_jrajkyc4tsa6w there are a bunch of folders (or shortcuts to other folders, apparently? The logo is shortcut but the type says folder...)

image

Most of them seem empty, or contain folders that are also empty, except "SystemAppData"

SystemAppData\Helium contains User.dat and UserClass.dat

SystemAppData\wgs contains.. this, the date of which corresponds to when I last started the game (just earlier to check if I still had my save): image

"t" is empty, the other one then contains this: image

and FINALLY, these extensionless files: image

I wonder if these extensionless files are the saves, the one from yesterday at 18:27 is pretty much exactly when I stopped playing my character.

Originally posted by @Flandre5carlet in https://github.com/Razzmatazzz/RemnantSaveManager/issues/44#issuecomment-842670681

Razzmatazzz commented 3 years ago

The save folder appears to be: %LocalAppData%\Packages\PerfectWorldEntertainment.RemnantFromtheAshes_jrajkyc4tsa6w\SystemAppData\wgs\[hexadecimal characters]_[hexadecimal characters]\[hexadecimal characters]

In the above picture, 2C49697FF53A4BDDB2C0C9294C973DEB corresponds to save_0.sav and the other file corresponds to profile.sav.

It is currently unknown if there's a predictable system to the folder and file naming.

Flandre5carlet commented 3 years ago

Here are the three files in the folder. I'm assuming the naming of at least one of the folders in the path is some kind of "user id" relating to your Microsoft account, but 🤷

97E93B75654546BE879688747DAA48F3.zip

I could try to create additional characters to see if there's any sort of coherence in the naming of the files, similar to save_0, save_1, etc.

Razzmatazzz commented 3 years ago

Thanks. It looks like the container.192 file might be used to map out the save files in some way. If you could create another character and upload the files in that folder again, that would help tease things out.

Flandre5carlet commented 3 years ago

Sure thing, when I'm able to I'll create one or two additional characters and post all the files here.

Flandre5carlet commented 3 years ago

Okay, here it is.

97E93B75654546BE879688747DAA48F3.zip

I logged in my main character, then made two additional characters which I started up and played like, 30 seconds of the tutorial, then closed the game.

Seems like the file names have changed... In fact it seems like the file names completely change pretty much whenever the game touches them. I opened up the game again and started up my main character, and, during the loading the filename changed to other hex gibberish, then when I closed the game, it had yet another new hex name.

Razzmatazzz commented 3 years ago

Thanks. That definitely some pretty odd behavior for the save files. Won't make supporting the Windows Store version simple, that's for sure.

Out of curiosity, did you happen to create and delete a character before your "first" character from the first files you sent me? In the container.192 file, I see a reference to save_1 (which corresponds to the first character's world save, I believe) and then in the new container.218 file I see references to save_0, save_1, and save_2. Seems odd that it would switch from the first save being 0 to the first save being 1 unless the initial "0" save was created and deleted.

Flandre5carlet commented 3 years ago

Oh yeah, that's correct! I did initially create one character but realised I messed something up on the appearance so I deleted it without playing it, and made a new one. So on the new files I sent there's: -My current character which was played a few hours - which is technically the second character I made, with the first one having been deleted without even being played. -Two new tutorial characters.

Razzmatazzz commented 3 years ago

Got it, good to know we're figuring something out. Can also confirm the save file names are actually GUIDs that are referenced in the container.### file.

I'm not sure if the backup/restore features will work well with the Windows Store version. All these oddities might be related to a cloud save feature that could cause problems.

Flandre5carlet commented 3 years ago

That's possible. I'm assuming there may be cloud save features linked to the Microsoft account that you might not be able to tamper with (eg. unlike Steam where it detects a discrepancy and asks you which one to use, I'd wager Microsoft would simply overwrite your save if it's different from the cloud's, but I have no real idea whether that's the case or not, maybe it's the opposite and the local save would overwrite the cloud one.)

From what I read online, on Xbox it does ask you which save to keep if there's a difference between local and cloud data when a game starts, so perhaps it'd work the same on PC but it'd have to be tested somehow, this is one of the only games I have on Microsoft Store so I never ran into the situation.

Razzmatazzz commented 3 years ago

rsm.zip The attached test build might work for backing up and restoring. I think it will work for the world analyzer, at least.

Flandre5carlet commented 3 years ago

Well, it opens! When going in settings, it has the proper folders listed. Active Save World Analyzer opens as well and shows me info so that seems functional/coherent? I'm not sure how to really verify it but it shows a bunch of things in there, at least. Clicking "backup active save" seemed to work.. once. It created a new folder and copied all the files there (including the other characters that I wasn't playing on), then a new line appeared in the main window albeit with "save date" being super wrong (it listed save date as 1/1/1601 at 1:00:00 AM). At this point it seems to stop working and doesn't really do anything further?

Flandre5carlet commented 3 years ago

Also, I can confirm that restoring will probably be a pain. It seems like if it detects an incoherence it simply resets your data and prompts you to make a new character. Figured fuck it might as well try it right? It seems like it just doesn't really detect the save files if they are not EXACTLY what the game expects to find, and so simply assumes you have no save and overwrites it with a new thing. Doesn't even prompt you with a cloud save incoherence or anything. (So I probably lost my character but I only really played for a few hours so eh)

At the very least it seems like it won't nearly be as simple as putting files in that folder again and expecting them to work, if it's possible at all.

Razzmatazzz commented 3 years ago

Thanks for helping test. I'm not sure that it will be possible to get the restore feature working with the Windows Store version.

In the meantime, I released a new version that has world analyzer support for the Windows Store version. For anyone else who comes by: DO NOT attempt to restore your saves if you have the Windows Store version. You will likely lose your progress.

Flandre5carlet commented 3 years ago

One can only hope that the Windows Store version has fixed whatever issues the saves had in other versions, but otherwise yeah, I'm assuming the container file has to do in some way with how the game detects your saves being coherent or not and whether it loads your saves or boots up a new save.