Example #1
0
 void ComponentCheck()
 {
     if (actionBarScript == null)
     {
         actionBarScript = FindObjectOfType <ActionBarScript>();
     }
     if (cinemachine == null)
     {
         cinemachine = FindObjectOfType <Cinemachine.CinemachineVirtualCamera>();
     }
     if (battleUIScript == null)
     {
         battleUIScript = FindObjectOfType <BattleUIScript>();
     }
     if (uIHandlerScript == null)
     {
         uIHandlerScript = FindObjectOfType <UIHandlerScript>();
     }
     if (questManager == null)
     {
         questManager = GetComponent <QuestManager>();
     }
     if (playerManager == null)
     {
         playerManager = FindObjectOfType <PlayerManagerScript>();
     }
 }
Example #2
0
    void Start()
    {
        _uiHandler = this.GetComponent <UIHandlerScript>();

        StartCoroutine(StartLocation());
        currentUser = FileAndNetworkUtils.getCurrentUser();

        /*Debug.Log("CURRENT USER : "******"CURRENT USER JOB : " + currentUser.mission);
         * Debug.Log("CURRENT USER ID : " + currentUser.id);
         *
         * saveButton = XRUXPicker.Instance.GetDemoButton();*/

        feedbackBox = XRUXPicker.Instance.GetFeedbackText();

        ReferencePointCreator = FindObjectOfType <ReferencePointCreator>();
        ReferencePointCreator.OnObjectPlacement += ReferencePointCreator_OnObjectPlacement;

        feedbackBox.text = "Starting Session";
        if (ARSession.state == ARSessionState.SessionTracking)
        {
            var startAzureSession = StartAzureSession();
        }
        else
        {
            ARSession.stateChanged += ARSession_stateChanged;
        }
    }