using UnityEngine; using System.Collections; using UnityEngine.UI; public class GPSLoader : MonoBehaviour { public Text label; IEnumerator Start() { if (!Input.location.isEnabledByUser) { label.text = "Error"; yield break; } Input.location.Start(); int maxWait = 120; while (Input.location.status == LocationServiceStatus.Initializing && maxWait > 0) { yield return new WaitForSeconds(1); maxWait--;