I have one “Gate” actor in my level, it’s using as trigger like this :
If charracter touching to this actor, gameplay open my level :
My problem right here :
My DatacenterGameRef get reference from my DatacenterGame actor ( where i stock user name and user index, and other variables for save game )
But when gameplay start, nothing already created in DatacenterGame. So it’s none inside.
After gameplay running, as in my logic, i checking Does save game exit, i wanna get slot name and slot index in DatacenterGame to check, but has nithing in there so this’s first bug.
Then next after i check does save game exits or not, i have 2 choice :
- True : LoadGame function running
- False : Creating save game object then save game to slot
All after that execution flow keep going and save game by SaveGame function :
Then if player character touch to “Gate” actor as trigger, my game play open level as new level.
Here’s second problem with me, level open always is basic level, variables i saved before didn’t showing up or it’s not got save and new level open always is basic ( mean DatacenterGameRef always none when new level open ).
What should i changing here to save my variables to save game and load it after new level open ( by let character touch to trigger ) ?