marius00 / iagd

MIT License
108 stars 33 forks source link

Decrypting save files #98

Closed recursivelftr closed 3 years ago

recursivelftr commented 3 years ago

Hi,

First, I'd like to say thank you for Item Assistant, it is a great tool for Grim Dawn.

I have a question about how you decrypt the character and stash save files. Looking at the code, you seem to know the order of the values in each file.

For instance version 5 of the stash (*.gst) file has a different value order than version 4. What tools did you use to figure out that order for each save file?

marius00 commented 3 years ago

Hi.

IA does not read character files, only transfer stashes. The parsers are based on the code from GD Stash. When there are breaking changes in the file format, I use IDA Pro to analyze the code in GD which writes the stash files, failing that I ask Mamba (GD Stash) if he knows what changed.

I'm unsure what methods Mamba uses, but I know its not IDA, might be diffing the files? Unsure..

recursivelftr commented 3 years ago

Thanks that is helpful. I'm writing an app for the JVM so seeing Mamba's code would help a lot. I searched but it looks like the GD Stash code is not available on GitHub, did you ask him for it directly or decompile GD Stash?

marius00 commented 3 years ago

I asked him and he sent the code over.

Via forum PM.

marius00 commented 3 years ago

Closing this unless there are more questions.

Easiest would be to just drop by #dev on the IA discord if you need anything.