Messages

If DISE is stuck trying to update, run this command in Command Prompt.

Tuesday, October 4, 2011

Tutorial: Fixing a corrupted game-save

Cool update:
The editor can now fix game-saves using the method I explain here. :)

Cooler update:
The editor can now recover all of your (salvageable) quest progress! :)

Update 2: I tried reducing the size of the text boxes, but now they're too small. I'll make some time to make the images more clear (crop them to make them larger) soon. Please bear with it for now, but please let me know if it is hard to follow the tutorial.

Update 3: I'll try to figure out how the quest progress data works when I have time, so that you're less likely to lose all of your quest progress, or at least less likely to get stuck without being able to do any quests. I realized that even if your save works after fixing it, maybe your current location could prevent you from completing earlier quests (since your later ones were cleared). In that case, maybe simply changing your spawn point could help. Of course, I'll implement that in my editor some time as well.


If your game-save was corrupted for real (because you had too many items in your inventory, perhaps), chances are that you will lose some data, and especially your quest progress. If you want to try fixing your game-save manually, I'll attempt to explain what I have been doing. Sometimes, the result is very successful! Note: This tutorial is now considered outdated until I update it!

You'll be able to try this by yourself with a game-save I made. In the end, you should have a working game-save (even if quest progress is lost).

If you simply want to see that the game corrupts your game-save, you can download the game-save, load the game, then quit the game (to save). You should then have the same corrupted game-save as you can also download here.


Download


What you need

  • Hex editor (I use Hex Workshop, but there are free alternatives)
  • Corrupted game-save
  • gzip (de)compressor (7-Zip)

Make a backup copy

You probably know this already, but please backup your game-saves as well as your corrupted one, just in case. :)

Let's get started!

The game-save is compressed with gzip, so you need to extract the file inside. If you use 7-Zip, you should be able to simply right-click the .sav file and extract it.

Now that you have your save_0 file, it's time for some hex-editing!

The hex editor

media_1317730709828.png

Here we have the hex editor with save_0 loaded and ready. Make sure to use Little Endian byte order (1).

Find the right offset

Note: If you use Hex Workshop, you can now use my bookmarks to make it easier to locate sections. Please find it here: Easier method to find sections in game-saves

media_1317729737432.png

media_1317729670356.png

Note the section size (AF 00 00 00 as hexadecimal, or 175 as decimal). If you use the hex value, you have to swap/reverse the byte order. It means that AF 00 00 00 backwards, becomes 00 00 00 AF, and you can remove the leading zeros so that you have just AF in the end.

media_1317731025782.png

Skip the selection, so that the caret is on the right place where we'll jump from (1). We'll jump from the current position (2). As you saw in the last step, the decimal (3) value was 175 (4). You can choose "Hex" as well and just type in "af".

media_1317731226399.png

We land on the next section. All of the player state data is stored here. We'll skip this section as well, so do the same as in the last step.

media_1317733548506.png

We are now close to the end of the file, and this is also where the problem usually resides.
If you're not on section 67, then this tutorial will unfortunately not work for you, as the player state data is also corrupted, and requires a lot more work to repair. :(

You can try to skip this section as well. If you end up on section 68, then you're lucky, and your quest progress should also be salvageable! In this case, we end up at the end of the file, so parts of the data about quests is missing. You may not even be able to jump to that offset, and your quest data is damaged in this case as well.

Section 67 stores main/side quest progress. The first uint32 value (1) in this section is the size of the (only chunk of) data in this section. The size is 385 bytes, however, the file does not have that much more data. It's gone! :(

If you skipped this section and ended up on section 68, please work with it instead of 67 from now on.

Make a new game-save

Update: I came over someone saying that you should start the game from an earlier chapter. I have no idea at the moment.

Start a new game from the same chapter as you were on (maybe it makes a difference, or maybe not), and then quit the game. We'll copy data from this new game-save, so please extract the new .sav file and open it in the hex editor. Please don't lose track of which file is the old and new one.

Fixing the corrupted game-save

media_1317740479213.png

Delete this section from the corrupted save (remember to work with section 68 if you have it, or even 69 if you're that lucky).

media_1317740816860.png

Switch to the newly made save-game and locate the same section.

media_1317740988437.png

Select and copy everything in the file from this point and onwards.

media_1317741291866.png

Switch back to your corrupted save, then paste at the end of the file. Save it and then re-compress it (name it save_0.sav, and remember to use the gzip format).

Testing

You can now try the fixed game-save in-game, and sell the items you don't need. Alternatively, you can remove items with the editor.

18 comments:

  1. Hi Steffen,

    Somhow i managed to get my save up and running after this tutorial! Thanks for the help mate!

    ReplyDelete
  2. Thanks for the feedback! I'm so happy it worked for you! :D

    ReplyDelete
  3. I didn´t understand this part:

    Note the section size (AF as hexadecimal, or 175 as decimal). If you use the hex value, you have to reverse the byte order (AF000000 -> 000000AF -> AF). In this case, it's easy and we don't need to reverse it.


    Please can you fix my save game. I have too many items :(

    This is my save game: http://www.megaupload.com/?d=66DBNH70

    Thanks in advance

    ReplyDelete
  4. Hello, Brian. Please e-mail me if you need an explanation. Would be good for me as well to know exactly which part(s) you did not understand, so that I can improve the tutorial. Of course, it's assumed that you have basic knowledge about what a bytes are, as well as hexadecimals. Also, it's easier for me if you also e-mail me about your game-save. It's easier for me to keep track of things, and keep support cases outside of the commenting area. :) Thanks!

    ReplyDelete
  5. I updated the tutorial.
    Changes:
    - Changed word "reverse" (byte order) to "swap".
    - Hopefully, I made the part Brian didn't understand, easier to understand. :)

    ReplyDelete
  6. Look:

    [img]http://www.imagengratis.org/images/save0.png[/img]

    Mine says C42C8B946A, when i swap the bits it becomes A649B8C24C, that it is 71420146268 in decimal.

    Maybe your tutorial won´t work for me :(

    ReplyDelete
  7. Btw, where can i find your email?

    ReplyDelete
  8. It's on my Support/Contact page.
    It'll (most likely) work for you once you extract your .gz/.sav file first. :)
    However, please make sure to swap every byte value (displayed in the hex editor as a group of two digits/letters), not every digit/letter.

    ReplyDelete
  9. I updated the tutorial.
    Changes:
    - Text under "Let's get started" should be more clear now. :)

    ReplyDelete
  10. Thank you so much. It worked :D

    and i added more money for my player too :p

    ReplyDelete
  11. I'm happy it worked out for you! :D

    ReplyDelete
  12. Hi Steffen, sadly i can't restore my corrupted savefile.
    Had Logan with level 44 and of course too much items.
    When i start DISE it says Quests corrupted and so it was.
    i could get rid of items to downsize the file but all my quests where gone. :-(

    Its not possible to change quests and challenges with your editor, isn't it?
    Also i have problems with the strenght of the weapons i give to an character in a new game.
    For example Xian. i give her with your editor level 43 and some weapons in orange. Works fine but the weapons are extremly powerless. Deathstalker Zeds Demise with strength 300 is way to low. Espeacially when all enemies are now also level 43.
    how can i increase the power of weapons? do you have a tutorial for this?

    Anyways - thanks for your great work!
    Andi

    ReplyDelete
  13. Andi, please e-mail me your game-save. Maybe I can restore some of the quest progress manually.

    As for the weapons, you could try a value of 4294966628 for the attributes. Please let me know how it works for you! :)

    ReplyDelete
  14. Thanks for your fast reply. i'm @work now so i send it later.
    Thanks again for your help...
    Andi

    ReplyDelete
    Replies
    1. Please don't mention it! :)
      I hope I can at least do something about it.

      Delete
  15. Could you teach how to manually make quests completed? I have the very same problem that andi does, when i open my save with dise, it puts me right of the office of the Lifeguard, but locked as if I still needed to be on the hotel for the introduction. lots of programer markings apear everywhere and I'm forever stuck outside without a single quest to start again...

    So could you make a tutorial on the quests adress or what kind of structure should I be searching for?

    For elses, I just wanted that someone made a savefile unbugged that was in the 3rd or 4th chapters with all the resort sidequests done, because I restarted the game for the 5th time already and I realy can't stand going for that teddy bear again or worse those juice crates.

    ReplyDelete
  16. hi, what i must do to change spawn point? i dont rly got it form tutorial..my problem is that in chapter 9 , after i go to hotel for the Radio and spoken with rider whyte, cutscene, a new quest added (but i dont noticed it, the quest given by the lost keys found in front of the hotel door) returned to resort, spoken with the Van girl, quest triggered..but i noticed that i had a new secondary quest (from the key i found at Hotel) so left the van and the girl, go to the secondary mission mark (named home sweet home ), but after the 20 seconds mission failed...(the main one i mean) so Hit space bar to restart from chekpoint and game spawn me in front of the hotel...with 20 seconds to retunr to the Van girl...and this is of course impossible..so questa fail again and loop...i can edit my save game and coninue the game without loosing nothing? thanks and sry bad english

    ReplyDelete
  17. hey i did all that i wanted to the dise you know i set some weapons i set all the level and stats but how to save it i mean how to deposit that i did in my dead island game i made all but i dont know how to save it to dead island i make it and i dont close dise and i get to the game but it doesnt show up what i did in dise what to do ???

    ReplyDelete