- Home /
what is the right way to change scenes?
my game include 3 scenes: spalsh, menu, game scene. when i start my game everything works fine. splash load -> menu load and when i hit play the game load. my pause menu include button to return menu. this button simply load again the menu scene but it seems that it doesn't load correctly and the camera script doesn't work well. if i hit "play" again the game scene load but once again it doesn't work well. once again problems with the scripts on the camera...
any idea what i'm doing wrong?
What does your script that handles the level loading looks like?
Answer by haim96 · Nov 23, 2013 at 06:53 PM
stupid me! i have a state machine code that doesn't destroy between scenes. this also hold the pause status. when i press the pause button i'm setting time.timescale=0. but i didn't set it back to 1, that's why nothing move in the menu screen.
XD Don't you love it when you solve something like that. Glad you figured it out!
Yap! to be honest your comment helped... until now i was thinking that something wrong with UNITY. your comment made me check my code again. some time i need that kind of push... thanks! :)