Пример #1
0
 void OnTriggerEnter2D(Collider2D other)
 {
     if (other.tag == "foot" && transform.parent == null)
     {
         transform.parent = other.gameObject.transform;
         shoesWorn++;
         //transform.localPosition = Vector3.zero;
         if (shoesWorn >= 2 && !WinText.beenTrig)
         {
             trumpets.Play();
             AddWobble.bedSounds = false;
             WinText.ActivateWinScreen();
         }
         else
         {
             Debug.Log(shoesWorn);
         }
     }
 }