Page 1 of 1

Cannot load a saved game

Posted: Tue Jan 01, 2019 8:34 pm
by KasperJanssens
Last version, 0.7.2, used DaggerfallSetup for the daggerfall files. Started privateer's hold, saved halfway, loading the game does not crash but as soon as I load the game itself does not render, I keep on seeing the 'Load Saved Games' screen. Saved game can be attached if necessary. Not sure how to provide more debugging info, do not really see anything in the console. Oh yes, Ubuntu 18.04.

Re: Cannot load a saved game

Posted: Tue Jan 01, 2019 9:28 pm
by Interkarma
Welcome to the forums KasperJanssens. :)

Please provide a copy of your save game amd we will take a look at it. You'll find save games in the persistent data path that is shown at the bottom of startup UI when launching game. This varies by platform.

The bug guidelines topic has some more information on persistent data path identifying saves.

Re: Cannot load a saved game

Posted: Fri Jan 04, 2019 9:04 am
by LypyL
I just tested this w/ Ubuntu in a VM & using Build 0.72 and experienced the same issue. This was the exception in the log:
KeyNotFoundException: The given key was not present in the dictionary.
at System.Collections.Generic.Dictionary`2[System.Int32,DaggerfallConnect.Arena2.FactionFile+FactionData].get_Item (Int32 key) [0x00000] in <filename unknown>:0
at DaggerfallWorkshop.Game.Serialization.SerializablePlayer.RestoreFactionData (DaggerfallWorkshop.Game.Serialization.FactionData_v2 factionData) [0x00000] in <filename unknown>:0
at DaggerfallWorkshop.Game.Serialization.SerializableStateManager.RestoreFactionData (DaggerfallWorkshop.Game.Serialization.FactionData_v2 factionData) [0x00000] in <filename unknown>:0
at DaggerfallWorkshop.Game.Serialization.SaveLoadManager+<LoadGame>c__Iterator2.MoveNext () [0x00000] in <filename unknown>:0
at UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress) [0x00000] in <filename unknown>:0
Trying to load a classic save resulted in the same error.

Re: Cannot load a saved game

Posted: Fri Jan 04, 2019 9:10 am
by Interkarma
This is a fairly common issue where user has a bad copy of FACTION.TXT. I'm not sure, but I think one of the translation packs or unofficial fixes in Daggerfall Setup is the culprit.

Try downloading the known-good "DaggerfallGameFiles.zip" from Live Builds and replacing your FACTION.TXT file with the one from that archive. You should also delete the "FactionData.txt" file from your affected save.

Lypyl, without a save game from OP there's no way of knowing if you two have the same issue or not. But an incompatible FACTION.TXT is a fairly common problem and has been raised several times. :)

Re: Cannot load a saved game

Posted: Fri Jan 04, 2019 9:43 am
by LypyL
Ah, I see the problem. DaggerfallSetup gives you faction.txt (depending on if you select the patches it seems), while FactionFile wants FACTION.TXT, which was an issue on Linux as it's case sensitive. I'm using the same install for both so I knew the file itself was fine.

Re: Cannot load a saved game

Posted: Fri Jan 04, 2019 10:51 am
by pango
I thought .NET runtime (Mono in this case I assume) was doing case matching on its own to avoid this problem... (?)

Re: Cannot load a saved game

Posted: Fri Jan 04, 2019 11:06 am
by LypyL
I just went and double checked by renaming the known good faction file to faction.txt and making a new save with it - Faction data in this save game is empty resulting in the exception I mentioned above. I don't have the editor installed so I can't go deeper than that atm.

Re: Cannot load a saved game

Posted: Tue Jan 08, 2019 3:44 am
by Interkarma
Right, I'm officially done with FACTION.TXT causing issues. Every time someone has a problem with starting the game for the first time, this file is almost always the culprit. I've been dealing with problems from this file for years thanks to unpatched game files, custom edits and translations, bad or missing data, and now casing in case-sensitive file systems. There's only so much I can handle. :)

From now on, I'm including a known-good and nicely patched version of FACTION.TXT in StreamingAssets/Factions folder. Where previously FACTION.TXT was loaded from Arena2, it will instead be loaded from StreamingAssets. End users are still free to edit or replace this file if they wish.

In the near future, I'm likely to replace the entire FACTION.TXT file with a JSON export of this data, which is a much better fit for this kind of data in any case.