Пример #1
0
    IEnumerator Start()
    {
        OnboardingManager mng = FindObjectOfType <OnboardingManager>();

        uiLineRenderer = doorIndicator.transform.Find("UI LineRenderer").GetComponent <UILineRenderer>();
        doorButton     = doorIndicator.transform.Find("DoorButton").GetComponent <RectTransform>();
        rayManager     = FindObjectOfType <ARRaycastManager>();
        cam            = Camera.main;

        // Extract needed placement helper objects from parent
        placementColliderObj = placementHelpers.transform.GetChild(1).gameObject;

        // Get the collider attached to the child object
        placementCollider = placementColliderObj.GetComponentInChildren <Collider>();

        scale = FindObjectOfType <ScalingManager>();

        // The point cloud needs a moment to be created by the pointCloudManager,
        // therefor wait until onboarding is done
        while (!mng.GetComplete())
        {
            yield return(null);
        }

        cloud = FindObjectOfType <ARPointCloud>();
        Debug.Log(cloud);
    }
Пример #2
0
        private static void OnBoarding()
        {
            if (!Settings.Instance().OnboardingMode || OnboardingManager.Instance != null)
            {
                return;
            }

            GameObject        tutorial = new GameObject("Tutorial Mode");
            OnboardingManager manager  = tutorial.AddComponent <OnboardingManager>();

            manager.Init(_requiredProjectArguments.GameMode);
        }
    IEnumerator Start()
    {
        OnboardingManager mng = FindObjectOfType <OnboardingManager>();

        scale        = FindObjectOfType <ScalingManager>();
        imageToWorld = FindObjectOfType <ImageToWorld>();

        while (!mng.GetComplete())
        {
            yield return(null);
        }

        Debug.Log("CameraImageManipulation -> Ready");
        cameraManager = Camera.main.GetComponent <ARCameraManager>();
    }
Пример #4
0
    IEnumerator Start()
    {
        OnboardingManager mng = FindObjectOfType <OnboardingManager>();

        scale = FindObjectOfType <ScalingManager>();

        touchIndicatorTransform = touchIndicator.GetComponent <RectTransform>();
        touchIndicatorImg       = touchIndicator.GetComponent <Image>();
        touchIndicator.SetActive(false);

        while (!mng.GetComplete())
        {
            yield return(null);
        }

        Debug.Log("TouchManager -> Ready");
        ready = true;
    }
Пример #5
0
    void Awake()
    {
        if (instance == null)
        {
            instance = this;
        }
        else if (instance != this)
        {
            Destroy(gameObject);
        }

        DontDestroyOnLoad(gameObject);

        for (int i = 0; i < obs.Length; i++)
        {
            obs[i].SetActive(false);
        }

        obs[0].SetActive(true);
    }
Пример #6
0
    IEnumerator Start()
    {
        OnboardingManager mng = FindObjectOfType <OnboardingManager>();

        foreach (Transform child in hiddenUntilReady)
        {
            child.gameObject.SetActive(false);
        }

        while (!mng.GetComplete())
        {
            yield return(null);
        }

        foreach (Transform child in hiddenUntilReady)
        {
            child.gameObject.SetActive(true);
        }

        Debug.Log("Buttons -> Ready");
    }