Reset Scene from a Pause Scene (iPad Bug)
Hi everyone,
I created a pause scene with a reset button, a game scene and a game attribute to switch between reset on or off that goes like this:
/Pause Scene - Reset Actor
When touch is pressed:
unpause game
game.reset to true
/Game Scene - Reseter Actor
when game.reset is true
reset scene
So when you test it on the mac previewer it causes a glitch, it seems like the attribute constantly resets the scene so I added the following line to my Reseter Actor in the Game Scene after the reset scene action:
game.reset to false
When I hit preview in the mac, it works perfectly, it DOES reset the game scene and unpause the game, works great, but when I hit Preview on my iPad and I hit the reset button it shows the loading animation and the game hangs in there, doing nothing.
I want to know if this is only an iPad issue or I'm doing something wrong.
The other choice I have is to make a pause scene for EVERY level in my game and that reset button will only change to my level scene but I don't know if my memory will overload and slows by duplicating the number of scenes per level by adding a pause scene to each one.
Many thanks in advance,
Lordal Zero
I created a pause scene with a reset button, a game scene and a game attribute to switch between reset on or off that goes like this:
/Pause Scene - Reset Actor
When touch is pressed:
unpause game
game.reset to true
/Game Scene - Reseter Actor
when game.reset is true
reset scene
So when you test it on the mac previewer it causes a glitch, it seems like the attribute constantly resets the scene so I added the following line to my Reseter Actor in the Game Scene after the reset scene action:
game.reset to false
When I hit preview in the mac, it works perfectly, it DOES reset the game scene and unpause the game, works great, but when I hit Preview on my iPad and I hit the reset button it shows the loading animation and the game hangs in there, doing nothing.
I want to know if this is only an iPad issue or I'm doing something wrong.
The other choice I have is to make a pause scene for EVERY level in my game and that reset button will only change to my level scene but I don't know if my memory will overload and slows by duplicating the number of scenes per level by adding a pause scene to each one.
Many thanks in advance,
Lordal Zero
Comments
When paused I have a reset button. When you hit that, it sets resetgame to true and after ,1 seconds it unpauses the game. Then I have a rule that says if resetgame is true after .1 sec reset the scene
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
I tried to make something like you said, adding a 0.000001 timer to the Reset Button on the pause scene but I didn't added the .1 timer to reset the scene after.
Really many thanks, you made my day