Beispiel #1
0
 void morrer()
 {
     if (!morreu)
     {
         morreu = true;
         ChecaIni checa = checaini.GetComponent <ChecaIni>();
         checa.morreuUm();
         anim.SetTrigger("morrendo");
         drop();
         Destroy(this.gameObject, 1f);
         rbd.velocity = new Vector2(0, rbd.velocity.y);
     }
 }
Beispiel #2
0
 void morrer()
 {
     if (!morreu)
     {
         if (vida <= 0)
         {
             morreu = true;
             ChecaIni checa = checaini.GetComponent <ChecaIni>();
             checa.morreuUm();
             anim.SetTrigger("morreu");
             drop();
             Destroy(this.gameObject, 0.7f);
         }
     }
 }
Beispiel #3
0
 void morrer()
 {
     if (!morreu)
     {
         if (vida <= 0)
         {
             morreu = true;
             PlaySingle(morre, 1);
             ChecaIni checa = checaini.GetComponent <ChecaIni>();
             checa.morreuUm();
             anim.SetBool("morrendo", true);
             drop();
             Destroy(this.gameObject, 0.5f);
         }
     }
 }