Esempio n. 1
0
 void OnTriggerEnter2D(Collider2D other)
 {
     if (other.tag == "Player")
     {
         lvlman.AddPoints(gemPoints);
         Destroy(this.gameObject);
     }
 }
Esempio n. 2
0
 void OnTriggerEnter(Collider other)
 {
     if (other.tag == "Score")
     {
         GetComponent <AudioSource>().PlayOneShot(MyClip);
         scoreman.AddPoints(ScorerPoints);
     }
 }
Esempio n. 3
0
 void OnTriggerEnter2D(Collider2D other)
 {
     Debug.Log("inside trigger");
     if (other.tag == "plate")
     {
         lvlman.AddPoints(foodpoint);
         Destroy(this.gameObject);
     }
 }
Esempio n. 4
0
 void DestructionM()
 {
     Destroy(this.gameObject, 0);
     lvlman.AddPoints(mPoints);
 }