- Home /
Loading Level
As a pause menu option you are able to go to the main menu. The main menu is built into the game itself and is in the same scene. This plays an animation from the scene to the game in the space of 5 seconds. When you tap (because this is on android) the menu button it reloads the level using Application.LoadLevel. Now the issue is all find input has become unresponsive so I am unable to click anything on the screen. I do not have any DontDestroyOnLoad lines anywhere in my code, could someone please offer some potential issues that would be causing this?
As an update, it realizes that there is input after the level is reloaded, but it will not start the co routines. I took them out and just enabled the primary events and it stuffs a lot of the code up
Answer by OperationDogBird · Sep 03, 2012 at 03:48 AM
I had the same issue the other day, a lingering line of code from an earlier version of my menu was setting the Time.scale to 0 after i reset it to the original scale from the newer version. Do some debug logs in the initializers in your new scene and make sure the timescale is proper(not 0). I realized this was the problem because my co-routines would not fire when reloading the scene (same thing you stated above), then it was the matter of tracking down where timescale didnt get reset.
In short, debug the Time.scale
Will test it now but I have a feeling this is the exact issue since it is loading from a timescale 0.0 into one that relies on 1.0. It realizes input but doesn't follow with the coroutine. Will get back to you on the answer, thanks heaps for the quick response, I didn't realize the timeScale would carry cross scene.
I wasted hours trying to figure this, and it was this simple, thank you so much!!
Your answer
Follow this Question
Related Questions
Load Level in background and load it when key is pressed 2 Answers
reload level whilst saving certain objects, without dontdestroy() 2 Answers
Switching Levels 2 Answers
Application.LoadLevel wont work 0 Answers
timed out load level 2 Answers