Esempio n. 1
0
 public void Paused()
 {
     Admanager.CheckForAd();
     camPosition = transform.position;
     camRotation = transform.rotation;
     rotate      = true;
 }
Esempio n. 2
0
 void GameOver()
 {
     isGameOver = true;
     uiAnim.SetTrigger("GameOver");
     Admanager.CheckForAd();
     if (score > recordScore)
     {
         gameOvertext.text  = "NEW RECORD!";
         bestScoreText.text = "Best : " + score;
         recordScore        = score;
         LevelscoreManager.SavePlayer(allRecordStar, allRecordTime, recordScore);
     }
 }
Esempio n. 3
0
    public void LevelFinished()
    {
        am.PlayLevelPassed();
        levelPassed = true;
        float timeCurrent;

        timeCurrent = Time.timeSinceLevelLoad;
        if (timeRecord == 0 || timeRecord > timeCurrent)
        {
            timeRecord        = timeCurrent;
            levelFinishString = LevelFinishTextManager.RandLevelPassedText();
            allRecordStar[sceneBuildIndex] = stars;
            allRecordTime[sceneBuildIndex] = timeRecord;
            LevelscoreManager.SavePlayer(allRecordStar, allRecordTime, recordScore);
        }
        timeTakenText.text  = timeCurrent + " sec";
        timeRecordText.text = timeRecord + " sec";
        Admanager.CheckForAd();
    }
Esempio n. 4
0
 void Update()
 {
     if (levelPassed)
     {
         anim.SetBool("LevelPassed", true);
         levelFinishText.text = levelFinishString;
     }
     if (!levelPassed && player.position.y < -4)
     {
         anim.SetBool("LevelFailed", true);
         am.PlayLevelFailed();
     }
     if (player.position.y < -4)
     {
         if (!levelFailed)
         {
             Admanager.CheckForAd();
         }
         levelFailed = true;
     }
 }
Esempio n. 5
0
 void LevelPassed()
 {
     Admanager.CheckForAd();
     allCollected = true;
 }