LateUpdate

LateUpdate is called for every frame, if MonoBehaviour is enabled.

LateUpdate is called after all Update functions have been called. This is useful to order script execution. For example, a follow camera should always be implemented in LateUpdate because it tracks objects that might have moved inside Update.

Example

// Moves the object forward 1 meter per second
function LateUpdate () {
  transform.Translate(0, 0, Time.deltaTime*1);
}
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.137.176.166