Save game for procedurally generated level

Anyone know how to save items and characters that are procedurally generated.

I mostly understand the save game object.

Everything I have seen about ousave game assumes you know the actors to save in advance. I will be constantly adding and destroying actors how would I sort that out.


Saving is not the problem. Loading is.
You need a way to identify actors spawned in the level… A FGuid that you’re sure it’s unique and method to reconstruct that actor from data stored based on that Guid.

I think I have more questions now. I appreciate the effort though.

Hi there @Nobodikilla

I have the same issue for saving/loading Entities datatypes in our Bad Morfo Multiuser 3D Hyperbasher. My strategy is to serialize the datatype {key/value} into JSON Strings with my custom JSON Encode/Decoder. I then store the JSON String in a SaveGameObject. JSON Serializing is also better suited for network transfer and storage between online apps & databases. Its more work to setup the JSON encode/decode, but greater flexibility.

Say No to Hard Coded References… You’re going to have to designed Spawn system and game subsystems to be agnostic to any engine specific references, using your own ID reference system to handle references dynamically in-game, even if Entities are persistent during a play session. This can be simple or complex. I use ‘Name’ datatype variable to store identifiers.