Exemplo n.º 1
0
        public void SetRotation(float pitch, float yaw, float roll = 0f)
        {
            var cameraPitch = Math.Map(pitch, -Math.Pi, Math.Pi, Math.Pi / 2f, -Math.Pi / 2f);

            transform.SetLocalEulerAngles(new Vector3f(cameraPitch, yaw, roll));
        }