Exemplo n.º 1
0
 private void OnTriggerEnter(Collider other)
 {
     if (!full)
     {
         if (other.gameObject.GetComponent <pinnBall>() != null)
         {
             other.gameObject.GetComponent <pinnBall>().doDestroy();
             other.gameObject.GetComponent <pinnBall>().hitTarget(gameObject.transform);
             gameObject.GetComponent <dropZone>().enabled = false;
             filling.SetActive(true);
             GetComponent <AudioSource>().Play();
             full = true;
             LevelScript.newHoleFinsihed();
         }
     }
 }