void EndTutorial()
    {
        Sequence tutorialEndSequence = DOTween.Sequence();

        tutorialEndSequence.Append(nextText.transform.DOScale(0, .4f).SetEase(Ease.InElastic));
        tutorialEndSequence.Insert(.1f, AButtonImage.transform.DOScale(0, .4f).SetEase(Ease.InElastic));
        tutorialEndSequence.Insert(.2f, backgroundImage.transform.DOScale(0, .5f).SetEase(Ease.InElastic));

        tutorialEndSequence.onComplete += () => OnTutorialEnd.Invoke();
    }
Ejemplo n.º 2
0
        void Stop()
        {
            if (!isStarted)
            {
                return;
            }

            isStarted = false;
            OnTutorialEnd?.Invoke();

            Debug.Log("Tutorial ended", this);
        }
Ejemplo n.º 3
0
 private void OnContinueButtonPressed()
 {
     if (pageIndex < tutorialPages.Count)
     {
         UpdateCurrentTutorialPage();
     }
     else
     {
         Debug.Log("Tutorial has ended.");
         OnTutorialEnd?.Invoke();
     }
 }
Ejemplo n.º 4
0
 private void BeginTutorial()
 {
     if (PlayerPrefs.HasKey(PlayerPrefsKeys.TUTORIAL_KEY))
     {
         Debug.Log("Tutorial has already been done.");
         OnTutorialEnd?.Invoke();
     }
     else
     {
         PlayerPrefs.SetInt(PlayerPrefsKeys.TUTORIAL_KEY, 1);
         Debug.Log("Tutorial has begun.");
         OnTutorialBegin?.Invoke();
     }
 }