Example #1
0
    void Start()
    {
        basketMovement = GetComponent <BasketMovement>();
        audioSource    = GetComponent <AudioSource>();

        highScoreLoader    = FindObjectOfType <HighScoreLoader>();
        highScore          = highScoreLoader.GetHighScore();
        highScoreText.text = "High Score : " + highScore.ToString();
        UpdateScoreText();
    }
Example #2
0
 private void Awake()
 {
     if (instance == null)
     {
         instance = this;
     }
     else
     {
         Destroy(this.gameObject);
     }
 }