Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
hyejunjeong's avatar
hyejunjeong
Honored Guest
7 years ago

character rotation and head rotation

I am completely newbie. 
I want my character to rotate with vr head rotation. 
I tried it, but when I build and check it, the screen gets dizzy. 
Look at my code and tell me what went wrong. please help me.
(CenterEyeAnchor enters the 'head' and the player enters the 'character'.)


public class PlayerCtrlHead : MonoBehaviour {
    public Transform Head;
    public Transform Character;


// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
        Character.rotation = Head.rotation;
}
}
No RepliesBe the first to reply