예제 #1
0
    private void SetTargetAge(DateTime dateOfBirth)
    {
        DateTime dateNow = DateTime.Now;
        int      age     = dateNow.Year - dateOfBirth.Year;

        if (dateNow.Month <= dateOfBirth.Month)
        {
            age--;
        }

        MaxAdContentRating maxAdContentRating;

        if (age < 7)
        {
            maxAdContentRating = MaxAdContentRating.G;
        }
        else if (age < 12)
        {
            maxAdContentRating = MaxAdContentRating.PG;
        }
        else if (age < 16)
        {
            maxAdContentRating = MaxAdContentRating.T;
        }
        else
        {
            maxAdContentRating = MaxAdContentRating.MA;
        }

        // loadingManager.maxAdContentRating = maxAdContentRating;
        loadingManager.Load();
    }
예제 #2
0
    public void Update()
    {
        if (LoadingManager.canUseBackButton)
        {
            if (Input.GetKeyDown(KeyCode.Escape))
            {
                if (messageSystem.isInNewShapesMessage)
                {
                    messageSystem.HideNewShapeMessage();
                }
                else
                {
                    if (pauseButton.interactable)
                    {
                        PauseGame();
                    }

                    if (isInDeadMenu)
                    {
                        LoadingManager.Load(0);
                    }
                }
            }
        }


        if (LoadingManager.hasLoaded)
        {
            raycaster.enabled        = true;
            LoadingManager.hasLoaded = false;
        }

        if (messageSystem.isNewShapeMessageHidden)
        {
            messageSystem.isNewShapeMessageHidden = false;
            ShowMenu(true);
            ads.ShowReviveButton();
            anim.SetBool("IsDead", true);
            ChangeAllCoinsPositive(Values.currentCoins);

            if (Values.score > Values.highScore)
            {
                //newHighScoreMessage.DOScale(1, 1.5f);
                //newHighScoreMessage.DOAnchorPosY(-55, 1.5f);
                //newHighScoreText.DOFade(1, 1.5f);
                highscoreText.text = Values.score.ToString();
            }
        }
    }
예제 #3
0
 public void ExitMainMenu()
 {
     LoadingManager.Load(0);
 }
 public void LoadScene(int scene)
 {
     LoadingManager.Load(scene);
 }
예제 #5
0
 public void LoadMainMenu()
 {
     LoadingManager.Load(0);
 }
예제 #6
0
 public void Retry()
 {
     LoadingManager.Load(1);
 }
 public void OnClickStart()
 {
     Time.timeScale = 1;
     LoadingManager.Load(1);
 }
예제 #8
0
 //Заглушка
 protected virtual void Success()
 {
     LoadingManager.Load(4);
     Destroy(gameObject);
 }
예제 #9
0
 public void StartGame()
 {
     LoadingManager.Load(3);
 }
예제 #10
0
 public void GoToMainMenu()
 {
     LoadingManager.Load(0);
 }
예제 #11
0
 public void GoToStore()
 {
     LoadingManager.Load(2);
 }