Exemplo n.º 1
0
 public void AEEndOfDeathAnim()
 {
     timeUtils.TimeDelay(0.25f, () => {
         blink.BlinkPlease(() => {
             gameObject.SetActive(false);
         });
     });
 }
Exemplo n.º 2
0
 private void Desactivate()
 {
     physic.enabled = false;
     if (blinkAtTheEnd && !blinking)
     {
         blinking = true;
         blink.BlinkPlease(() => { gameObject.SetActive(false); });
     }
     else if (!blinkAtTheEnd)
     {
         gameObject.SetActive(false);
     }
 }
Exemplo n.º 3
0
 override public void OnStateUpdate(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     if (blink == null)
     {
         blink = animator.GetComponent <Blink>();
     }
     if (stateInfo.normalizedTime > stateInfo.length && !blinking)
     {
         blinking = true;
         blink.BlinkPlease(() => {
             Transform t = animator.transform;
             while (t.parent != null && t.parent.tag == "enemy")
             {
                 t = t.parent;
             }
             t.gameObject.SetActive(false);
         });
     }
 }
Exemplo n.º 4
0
 public void DeathAnimCB()
 {
     blink.BlinkPlease(NotifyDeath);
 }