Example #1
0
 void OnDisable()
 {
     if (over)
     {
         progress.AddPts(nbPts * (difficulty + 1));
     }
     else
     {
         GameObject  button      = GameObject.Find("MinigamesCanvas");
         AudioSource audioSource = button.GetComponent <AudioSource>();
         audioSource.PlayOneShot(Oh);
     }
 }