FINDarkside / TLD-Save-Editor

Edit The Long Dark save files
http://www.moddb.com/mods/the-long-dark-save-editor-2/downloads
MIT License
76 stars 31 forks source link

Version 2.14.2 save-corruption fix (may be) #17

Closed Pt-Djefferson closed 4 years ago

Pt-Djefferson commented 4 years ago

Change m_Timestamp variable type from DateTime to string. GlobalData.cs => public string m_Timestamp { get; set; } and GameSave.cs => SlotData.m_Timestamp = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");

The savegame remains a mess, but loadable mess (story and survive).

FINDarkside commented 4 years ago

Thank you!

If you want, you can create issues about the other stuff that's messed up. I'm not sure I'll keep maintaining this since the switch to IL2CPP made maintaining this a lot more tedious, but it never hurts to have documented issues.

Pt-Djefferson commented 4 years ago

OK. Glad to help. Have some data structure changes but need to do dome tests.

FINDarkside commented 4 years ago

To simplify things, most of the fields could be removed from the data classes . DynamicSerializable will take care that data isn't lost even if fields are missing from GlobalData. Most of the fields aren't used, but they are leftovers from the time I had the whole save format defined there.