Question by
DaiMangouDev · Feb 03, 2016 at 10:16 PM ·
c#rotationtransform
How to make the rotation of a child object of object A match the rotation of object B ?
I am having the weirdest problem in getting a child object A to match the rotation of Object B.
the name of the child is childObj
Whenever object B rotates, the rotation of object childObj seems to match but then the rotation of childObj slows and reverses.
childObj.transform.rotation = objectB.transform.rotation;
wont work
childObj.transform.Rotate(new Vector3(objectB.transform.rotation.x,objectB.transform.rotation.y,objectB.transform.rotation.z));
wont work
childObj.transform. rotation = new Quaternion(objectB.transform.rotation.x,objectB.transform.rotation.y,objectB.transform.rotation.z,1);
wont work
Comment