Should I clear arrays of pointers before saving struct to GameSave?

@Chatouille

Hey, I wanted to thank you for all your help with this question.

Before I close it, I was going to ask if you had any suggestions on how to achieve the same functionality without the path problem that arises from changing maps or PIE increasing the instance.

So far, I’ve thought about two solutions. However, I am not super keen on them due to the increase in complexity:

  1. Use a local/external database solution for the persistent data and load it to the GameInstance objects on start.
  2. Do a manual copy of the structs within the objects to a specific SaveGame file. Then on load pass the data to the GameInstance Objects and reinitialise.

The downside of both is that no pointers are saved. Also, the data needs to be flattened or modified.

Have to say that I am not very keen on either…

Anyway, thanks a lot for your help!