Ue4 save for mullite characters

when I save and load for more than 1 actor it loads the actor transform the same for all actor please help me

Show us how you’re saving and loading.


the first picture is save the 2nd is load

why didnt you reply ?

You only have 1 variable in the save game, it’s no wonder they’re all getting the same transform :slight_smile:

You need a variable for each actor you want to save. It would probably be an array of transforms.

I notice the thing doing the saving is a blueprint. Give the blueprint and ID, an integer. That way, when they come to save, they can put themselves in the array at the right slot. And when they load, the know which part of the array to load from.

Can You Explain how can i use the array with this because I don’t know how to use array or send my screenshot please

Do you still want to know? ( I saw you posted this again… )

Yes please

So you make a array variable in the save game for all transforms

image

Each blueprint has an integer ID, which you can set for each one ( if there’s a lot, tell me ).

image

And each blueprint saves it’s location like this:

( Obviously the actual code to use the save game is what you already have here. But you wouldn’t want to write that in every BP. So, you either need to use class inheritance, then they all have the same code, or you need to put it in a macro library. )

And each BP can load like this:

Again, you need the macro etc, but this is the concept. Each actor has an ID and uses one of the array slots.

You can have a macro like this

( it’s only what you have above ), and then saving is just as easy as

Thanks

but wait all these macro and nodes need to be in char bp

  • can you explain more about the id because if I create a variable int for the id the default will be 0 so each char will have 0

So This macro save and load or it just saves and where should I do it in each blueprint?

No, the save code goes in each actor. This system only works if each thing you want to save is a blueprint.

If you only want to save the position of static meshes, that’s a different thing.