Easy Save saves my prefabs, but loads very weirdly...
Posted: Sat Feb 24, 2024 8:11 am
Hello all,
I have encountered an issue that I am hoping someone can help me solve. I can save my prefabs using Easy Save, no problem. It creates a json file and I can see every prefab I have placed at runtime for testing purposes. Whatever prefabs I spawned in are all inside the file when I open it and review it. But for whatever reason, when I load that exact same json file, it loads one prefab, and worse, that prefab isn't even one of the ones I used for testing. This happens no matter how many new save files I create. If I have 10 save files with different names (and different prefabs that were saved inside of them), I get 10 loads of the exact same prefab. I am using a file browser to create the save file, so that the user can name their own save files and choose the save location. I don't think that has anything to do with what's happening, but I mention it just in case.
My method for loading is as follows:
public void LoadPrefabInstances()
{
var paths = StandaloneFileBrowser.OpenFilePanel("Title", "", "json", false);
if (paths.Length > 0)
{
prefabInstances = ES3.Load("prefabInstances", new List<GameObject>());
Debug.Log("Loading!");
}
}
I do see "Loading!" when I load the file. I just don't know what I have done wrong that's causing my load method to create this single lone prefab every time.
Also, I thought using Refresh from my Easy Save 3 Manager might help resolve the issue, but every time I hit refresh, a loading bar pops up and says Easy Save is doing things, before it finally moves to saying Unity is waiting to finish....but hangs up and never finishes. I let it go for an hour and a half tonight before I finally used the task manager to shut it down. I've since tried this several times (though I didn't go an hour and a half again), and each time it does it's Easy Save thing before moving to the "Unity is waiting to finish" message and hanging up again. Maybe my issue is tied to needing to refresh the ES3Prefabs list on the manager and not being able to?
I should probably mention I have, at last count, around 1500 prefabs. The last time I was able to get Easy Save to update before the whole hanging up thing started, my prefab count had doubled to over 3000 without me adding any new prefabs. Something is messed up, but I don't know what. Any help would be greatly appreciated. Thank you!
I have encountered an issue that I am hoping someone can help me solve. I can save my prefabs using Easy Save, no problem. It creates a json file and I can see every prefab I have placed at runtime for testing purposes. Whatever prefabs I spawned in are all inside the file when I open it and review it. But for whatever reason, when I load that exact same json file, it loads one prefab, and worse, that prefab isn't even one of the ones I used for testing. This happens no matter how many new save files I create. If I have 10 save files with different names (and different prefabs that were saved inside of them), I get 10 loads of the exact same prefab. I am using a file browser to create the save file, so that the user can name their own save files and choose the save location. I don't think that has anything to do with what's happening, but I mention it just in case.
My method for loading is as follows:
public void LoadPrefabInstances()
{
var paths = StandaloneFileBrowser.OpenFilePanel("Title", "", "json", false);
if (paths.Length > 0)
{
prefabInstances = ES3.Load("prefabInstances", new List<GameObject>());
Debug.Log("Loading!");
}
}
I do see "Loading!" when I load the file. I just don't know what I have done wrong that's causing my load method to create this single lone prefab every time.
Also, I thought using Refresh from my Easy Save 3 Manager might help resolve the issue, but every time I hit refresh, a loading bar pops up and says Easy Save is doing things, before it finally moves to saying Unity is waiting to finish....but hangs up and never finishes. I let it go for an hour and a half tonight before I finally used the task manager to shut it down. I've since tried this several times (though I didn't go an hour and a half again), and each time it does it's Easy Save thing before moving to the "Unity is waiting to finish" message and hanging up again. Maybe my issue is tied to needing to refresh the ES3Prefabs list on the manager and not being able to?
I should probably mention I have, at last count, around 1500 prefabs. The last time I was able to get Easy Save to update before the whole hanging up thing started, my prefab count had doubled to over 3000 without me adding any new prefabs. Something is messed up, but I don't know what. Any help would be greatly appreciated. Thank you!