I have 2 game objects, “A” and “B” for example. (Arb is the “A” rigidbody component) I’d like to move A in B.transform.position with rb.MovePosition (so if the objects collides it will stop or something). But with
Arb.MovePosition (B.transform.position);
it teleports. I’d like a Vector3.Lerp but with a rigidbody.
Any tips ?
Thanks for the help.
As you can see from the link below the question has already been answered
Basically you get the normalized direcion from your object to the target and you move your object along this direction with a given speed, which is multipied to Time.deltaTime to get m/s instead of m/frame
Also be sure to select a proper interpolation method for your rigidbody, otherwise you are going to get strange jittering
Hope this helps