Are serialized or side-by-side updates updated?

I am new to Unity5 and I am trying to create a simple game.

Expanding MonoBehaviour

, I get the Update () function. But I don't know how it works behind the scenes.

My question is whether the Update () functions are serialized (called one after the other) or parallelized where many MonoBehaviour

have their own functions Update

.

For example, if I have two scripts with their own update in each, will the Updates calls be simultaneously (parallelized) or called one after the other (serialized)?

If they are serialized, how do you determine the order?

+3


source to share


1 answer


By default, new MonoBehaviour scripts are executed in whatever order Unity compiles them. They don't start at the same time, they start one after the other.

If you want to specify the order of execution, you can do this:



Edit> Project Settings> Script Execution Order .

Further reading: Order of execution of event functions

+7


source







All Articles