- Home /
Move and Rotate object with "Parent" without Parenting
Hello, i want to "grab" a object and it should then follow the "hand" and behave like a object which is parented.
The position and rotation should updated in the exact same way as it would do when the object would be parented to the hand, but i want to caculcate the position/rotation myself without parenting the "grabbed" object to the "hand"
What i found so far is how to update the position, when the "grab" starts i store the offsets:
positionOffset = child.position - hand.position
And in the update loop i calculate the "grabbed" object position like this:
child.position = hand.position + (hand.rotation * positionOffset)
This works so far and the object moves with the parent, but how would can i do the same for rotation? The child should keep it's own rotation and rotate (in all directions) with the parent/hand
Answer by tormentoarmagedoom · Apr 05, 2018 at 12:53 PM
Maybe is not possible in your project, but you can always parenting them, rotate, and then unparenting again
Your answer
![](https://koobas.hobune.stream/wayback/20220612160125im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Changing the parent transform of the First Person Controller 1 Answer
I am having an issue with the rotation of a child 1 Answer
1st person Camera rotates suddenly in another direction when unparenting from a platform 1 Answer
Parenting messes with my rotated cylinders 1 Answer
Problem combining transform.rotation and hierarchical rotations 2 Answers