I have 2 layouts - Menu and Game
Global variable
Pause
Isplaying
I have a pause button that calls a function which will then create
pause menu
resume
quit
restart
For resume and restart event, it works correctly.
Upon resume touched - call function -destroy pausemenu
-set timescale to 1.0
-set pause to 0
-set isplaying to 1
Upon restart touched - - call function -destroy pausemenu
-set timescale to 1.0
-restart global variables to default
-restart layout
However, my quit event dont seem to be going back to the first menu layout
Upon quit touched - - call function -destroy pausemenu
-Go to Menu
-restart global variables to default
Can someone advise if there is something wrong with how I am putting in the events?
I basically just want to quit the 2nd(game layout) and go back to the 1st(Menu layout).