Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: akira on June 10, 2014, 07:05:27 AM
-
Hi all,
First of all, sorry for my english..
Okay, so here i am again..with a new question..i couldnt find any tutorial out there about my problem..or maybe i searched it wrong..
Im using energy bar toolkit for my health system..and using the love type energy given in the package..so far i know how to change the value when my player hits the enemy or traps..and the energy bar working fine..
My game setting is when player hits an enemy or traps, the energy will decrease by 1..and then the level will restart..
After restarted, all the game will be reset including my energy bar..So how can i save/keep my energy bar value after i restart/load the level? I tried using dont destroy on load action, but still no luck..
-
Make it a global variable.
-
Err..can u pls explain more details?
-
Anyone here care to help me? :(
-
You need to save your energy value into Playmaker 'global variable' to make it stay between the scenes.
I am not familiar with energy bar tool kit, but it would be maybe easier to make energy management completely with Playmaker.
-
You need to save your energy value into Playmaker 'global variable' to make it stay between the scenes.
I am not familiar with energy bar tool kit, but it would be maybe easier to make energy management completely with Playmaker.
Are you sure this will save between scenes?
Anyhoo,another way to do this is saving it in player prefs.
-
Yes it will stay between scenes, it resets when you close the application.