示例#1
0
    // hide menu without animation
    public virtual void Hide()
    {
        if (_tween != null)
        {
            _tween.ChangeSetState(false);
        }

        gameObject.SetActive(false);
    }
示例#2
0
 public void NavigasyonButton()
 {
     if (navOpen)
     {
         menuAnimasyon.ChangeSetState(true);
         menuAnimasyon.OpenCloseObjectAnimation();
         Kapatici.SetActive(false);
         navOpen = false;
     }
     else
     {
         menuAnimasyon.ChangeSetState(false);
         menuAnimasyon.OpenCloseObjectAnimation();
         Kapatici.SetActive(true);
         navOpen = true;
     }
 }
示例#3
0
 void Degistir()
 {
     götürme.ChangeSetState(false);
     getirme.ChangeSetState(false);
     götürme.rectTransform = dem;
     götürme.OpenCloseObjectAnimation();
     getirme.rectTransform = ahir;
     getirme.OpenCloseObjectAnimation();
     gizleme.OpenCloseObjectAnimation();
     Invoke("Cikar", 0.25f);
 }
示例#4
0
    void Cikar()
    {
        RectTransform tmp = dem;

        dem     = ahir;
        ahir    = tmp;
        demUsul = ahirUsul;
        Rastgele(ahir, false);
        cikarma.ChangeSetState(false);
        cikarma.rectTransform = ahir;
        cikarma.OpenCloseObjectAnimation();
        int kereInt = UnityEngine.Random.Range(1, 4);

        kere.text = kereInt + " kere";
        Invoke("Degistir", (demUsul.zaman * ritim * kereInt) - 0.25f);
        gizleme.OpenCloseObjectAnimation();
    }
    /*Logic
     * */
    public void StartAnimateNavigation(UIScreenAnimationSettings settings, IUIScreenController nextUIScreen = null, IUIScreenController currentUIScreen = null)
    {
        _animtionSettings = settings;
        _nextUIScreen     = nextUIScreen.baseGameObject;
        _currentUIScreen  = currentUIScreen.baseGameObject;

        _nextUIScreenTween.rectTransform = nextUIScreen.baseRectTransform;
        _nextUIScreenTween.ChangeSetState(false);
        _currentUIScreenTween.rectTransform = currentUIScreen.baseRectTransform;
        _currentUIScreenTween.ChangeSetState(false);
        //set layer position
        UIScreensLayerPositions();
        //set uration of tweens
        SetDuration();
        //set tween settings
        SetAnimationParams();
        //start animations
        StartAnimation();
    }