- Home /
Awake/Start/Update order
Hi all, according to this
http://unity3d.com/support/documentation/Manual/Execution%20Order.html
all Awake all called first, then all Start, and then all Update. That works the first time I load the level, but when I load it the second time, after a gameover, the Update of my GameManager is called before the Start of the player object. I checked the enabled field of the player during its Awake, and it's true. Also, if I keep reloading the level the order of the aforementioned calls looks totally random... I guess the order it's not guaranteed?
Answer by datorum · Jul 17, 2011 at 12:28 PM
there is written "first scene load" in the document, thus I guess restarting your Game doesn't really reloads the the scene and everything, hence the Execution Order is different. Destroy the whole scene maybe helps?
this maybe useful too: http://unity3d.com/support/documentation/ScriptReference/Object.DontDestroyOnLoad.html