示例#1
0
 private void FixedUpdate()
 {
     if (aiEnabled)
     {
         StartCoroutine(behavior.AIUpdate());
         currentBstate = behavior.GetState();
     }
 }
示例#2
0
 private IEnumerator AIUpdate()
 {
     while (aiEnabled)
     {
         behavior.AIUpdate();
         currentBstate = behavior.GetState();
         yield return(new WaitForSeconds(1f));
     }
 }