예제 #1
0
    private bool isClickedOnBorder;            //is there a click on a border

    // Use this for initialization
    IEnumerator Start()
    {
        if (cam == null)
        {
            cam = Camera.main;
        }

        isMobile             = PlatformChecker.IsAndroid() || PlatformChecker.IsIOS();
        firstStageInitailPos = firstStage.position;
        lastStageInitailPos  = lastStage.position;
        sliderInitialPos     = transform.position;

        if (sliderDotsComp == null)
        {
            sliderDotsComp = GameObject.Find("SliderDots").GetComponent <SliderDots> ();
        }

        lastPos     = prevPos = Vector3.zero;
        obTransform = transform;

        if (centerPoint == null)
        {
            centerPoint = GameObject.Find("Center").transform;
        }
        SetImages(1);
        stageCount = obTransform.childCount;
        yield return(0);
    }
예제 #2
0
    // Use this for initialization
    IEnumerator Start()
    {
        if (cam == null) {
                        cam = Camera.main;
                }

                isMobile = PlatformChecker.IsAndroid () || PlatformChecker.IsIOS ();
                firstStageInitailPos = firstStage.position;
                lastStageInitailPos = lastStage.position;
                sliderInitialPos = transform.position;

                if (sliderDotsComp == null) {
                        sliderDotsComp = GameObject.Find ("SliderDots").GetComponent<SliderDots> ();
                }

                lastPos = prevPos = Vector3.zero;
                obTransform = transform;

                if (centerPoint == null) {
                        centerPoint = GameObject.Find ("Center").transform;
                }
                SetImages (1);
                stageCount = obTransform.childCount;
                yield return 0;
    }