コード例 #1
0
 private void OnEnable()
 {
     AttackComp = GetComponentInChildren <AttackAnimator>();
     GetComponentInChildren <Animator>().runtimeAnimatorController = AnimationController;
     weapons.ForEach(t => t.SetActive(true));
     ObserverCollection.Call(StateEventLibrary.SUBSTATE_ENABLED);
 }
コード例 #2
0
 private void Update()
 {
     if (Target != null && !isMoving)
     {
         Target = null;
         print(gameObject.name);
         ObserverCollection.Call(StateEventLibrary.DESTINATION_REACHED);
     }
     UnitComponent.Animator.SetFloat("Speed", navMeshAgent.velocity.magnitude);
 }