- Home /
When does rigidbody.velocity affect?
I am writing a script in which I constantly change the velocity of a GameObject's rigidbody.
My question is: When does the 'rigidbody.velocity' value affect the gameobject's position? Does it affect it after Update() function? or it takes place is LateUpdate() or some time between that. I am asking this to resolve a race issue.
Answer by smoggach · Feb 17, 2015 at 10:03 PM
Physics has it's own update called FixedUpdate.
But we can edit FixedUpdate right? Do you mean that Physics's FixedUpdate is run after all FixedUpdate(s) we overwrite in scripts?
Yes FixedUpdate can be used the same way you use Update and LateUpdate Your object will get the call after physics is done perfor$$anonymous$$g its updates.
Your answer
Follow this Question
Related Questions
Setting a RigidBody's velocity messes with my custom gravity, not sure how to proceed. 0 Answers
Gravity slower when moving Rigidbody 0 Answers
I have a planetary gravity script; how do I make the object speed up? 1 Answer
Tranform Animation Curve ruins Gravity 1 Answer
Rigidbody velocity disables gravity 1 Answer