Beispiel #1
0
 public void Die(GameObject killer)
 {
     if (killer.CompareTag("Player"))
     {
         animator.SetTrigger("dead");
         PlayerAvatar player = killer.GetComponent <PlayerAvatar>();
         player.ChangeElement(ownElement);
         Destroy(gameObject, animator.GetCurrentAnimatorStateInfo(0).length);
     }
 }