Exemple #1
0
 void OnTriggerEnter2D(Collider2D other)
 {
     Debug.Log("Triggered with " + other.tag);
     if (other.tag == "Player")
     {
         counter.addPoint();
         Destroy(this.gameObject);
     }
 }
 public void addPoint()
 {
     pc.addPoint();
 }