Versions with this page:
Versions without this page:
设置或检索该陀螺仪的启用状态。
using UnityEngine; using System.Collections;public class ExampleClass : MonoBehaviour { public bool enableTilt; void OnGUI() { if (Input.gyro.enabled) GUILayout.Toggle(enableTilt, "Enable tilt control"); } }