Gyroscope.attitude
Declaration
public Quaternion attitude;Описание
Возвращает ориентацию (то есть ориентацию в пространстве) устройства.
using UnityEngine;
public class Example : MonoBehaviour { // Rotate the object to match the device's orientation // in space. void Update() { transform.rotation = Input.gyro.attitude; } }