This seems like it would be pretty simple, but I’ve tried about a dozen different things and can’t get it to work. I have a cube that is a child of an empty world transform, so the cube’s local position is 0,0,0; as is its rotation.
The cube has a rigidbody attached, so it gets bumped around and moves away from its original child position.
All I want to do is move this cube smoothly back it its local position of 0,0,0.
I can instantly move it with:
transform.localPosition = Vector3(0,0,0);
but this insta-move isn’t the effect I’m looking for. I can’t get lerp, slerp, or smoothdamp to move it correctly back to its child origin. Hope someone can help!