private void OnTriggerEnter2D(Collider2D collision)
 {
     if (collision.tag == "Player")
     {
         scoreADDON.AddPoints(pointValue);
         scoreText.text = "Score: " + scoreADDON.score.ToString();
     }
 }
Example #2
0
 private void OnTriggerEnter2D(Collider2D collision)
 {
     if (collision.tag == "Player")
     {
         scoreADDON.AddPoints(pointValue);
         scoreText.text = "Score: " + scoreADDON.score.ToString();
         GetComponent <Collider2D>().enabled = false;
     }
 }