Discovered locations persist across save/load [resolved]

Locked
R.D.
Posts: 379
Joined: Fri Oct 07, 2016 10:41 am

Discovered locations persist across save/load [resolved]

Post by R.D. »

If you discover a location, like a dungeon, then load a game where that location shouldn't have been discovered yet, it will be discovered in the loaded game anyway.

User avatar
Interkarma
Posts: 7242
Joined: Sun Mar 22, 2015 1:51 am

Re: Discovered locations persist across save/load

Post by Interkarma »

I'm not able to reproduce this, I'm sorry mate. I can confirm that discovery data is being restored completely from your save game and whatever live discovery state you had is replaced at time of load.

I also confirmed discovery does not persist across load in two different ways:
  1. Save prior to taking a quest. Confirm location is discovered after accepting quest. Reload game and confirm location no longer discovered.
  2. Save prior to running into an undiscovered dungeon rect. Confirm location is discovered after running into rect. Reload game and confirm location no longer discovered.
If you check your saved discovery data in the savegame supposedly taken prior to discovery time, the discovered location should be in that save data, as this file completely replaces any live discovery state on deserialization. It's possible you had just already discovered that location, or had actually saved after reveal.

And of course, it's always possible something else is going on. Happy to take another look if you can provide steps to reproduce. :)

R.D.
Posts: 379
Joined: Fri Oct 07, 2016 10:41 am

Re: Discovered locations persist across save/load

Post by R.D. »

I found the problem. The save I loaded was an old save, I think before location discovering was implemented. There is a message in the Unity log about not finding the discovery data file. So it seems in this case the discovery data from before load will carry over. Not sure if you want to bother worrying about this case. Feel free to mark this as not an issue.

User avatar
Interkarma
Posts: 7242
Joined: Sun Mar 22, 2015 1:51 am

Re: Discovered locations persist across save/load

Post by Interkarma »

Ah good, thank you for the extra detail. I can see how this would happen now. While probably not a major issue, I'll still try to smooth this wrinkle out. Cheers!

User avatar
Interkarma
Posts: 7242
Joined: Sun Mar 22, 2015 1:51 am

Re: Discovered locations persist across save/load

Post by Interkarma »

This is fixed now. When loading an old save without discovery data, current state will be cleared and not carried over from previous session.

Locked