Going to an specific scene

Hi, my app have five scenes called “scene1”, “scene2”, "scene3, “scene4”, “scene5”. In every scene I have a button to go to an scene called “menu_scene”. Also, inside “menu_scene”, I have two sections called “credits_scene” and “aboutUs_scene”, which are also scenes.

I have a button in the “menu_scene” to go to previous scene. So if someone is inside “scene1” goes to “menu_scene” and then goes to “credits_scene”, and then back to “menu_scene”, my prevScene button takes again to “credits_scene”. Can i handle the prevScene button to go to “scene1” and not to any section of the menu?

I hope I have explained this as best I can. 

Thanks

You probably need to share your previous scene handling code so developers can advise you. If you’re using composer.getSceneName(“previous”) then it’s not going to behave the way want since it literally will get the previous scene, not some arbitrary scene. Instead you’re going to need to keep track of your own “previousScene” variable and not set it when you go to credit_scene or other side scenes.

Rob

You probably need to share your previous scene handling code so developers can advise you. If you’re using composer.getSceneName(“previous”) then it’s not going to behave the way want since it literally will get the previous scene, not some arbitrary scene. Instead you’re going to need to keep track of your own “previousScene” variable and not set it when you go to credit_scene or other side scenes.

Rob