Unity 2D Games Developer Question:
Download Questions PDF

Explain me arrange the event functions listed below in the order in which they will be invoked when an application is closed:

Update()
OnGUI()
Awake()
OnDisable()
Start()
LateUpdate()
OnEnable()
OnApplicationQuit()
OnDestroy()?

Answer:

The correct execution order of these event functions when an application closes is as follows:

☛ Awake()
☛ OnEnable()
☛ Start()
☛ Update()
☛ LateUpdate()
☛ OnGUI()
☛ OnApplicationQuit()
☛ OnDisable()
☛ OnDestroy()

Note: You might be tempted to disagree with the placement of OnApplicationQuit() in the above list, but it is correct which can be verified by logging the order in which call occurs when your application closes.

Download Unity 2D Games Developer Interview Questions And Answers PDF

Previous QuestionNext Question
Explain me classic Arcade?What is animation Layer?