Ejemplo n.º 1
0
 // OnStateUpdate is called on each Update frame between OnStateEnter and OnStateExit callbacks
 override public void OnStateUpdate(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
 {
     if (minion == null)
     {
         minion = (MinionController)animator.GetComponentInParent <MinionController>();
         animator.SetBool("spawnCooldown", minion.isInSpawnCooldown);
         return;
     }
     animator.SetBool("spawnCooldown", minion.isInSpawnCooldown);
     target = minion.checkForPlayer();
 }