/// <summary> /// Awake is called when the script instance is being loaded. /// </summary> public void Awake() { TangoState tangoState; #if UNITY_EDITOR tangoState = m_editorPlayModeState; #else if (!AndroidHelper.IsTangoCorePresent()) { tangoState = TangoState.NotPresent; download.SetActive(true); } else if (!AndroidHelper.IsTangoCoreUpToDate()) { tangoState = TangoState.OutOfDate; download.SetActive(true); } else { tangoState = TangoState.Present; start.SetActive(true); } #endif foreach (GameObject obj in m_enableIfTangoPresent) { obj.SetActive(tangoState == TangoState.Present); } foreach (GameObject obj in m_enableIfTangoOutOfDate) { obj.SetActive(tangoState == TangoState.OutOfDate); } foreach (GameObject obj in m_disableIfTangoPresent) { obj.SetActive(tangoState == TangoState.NotPresent); } }