IEnumerator Start() { enemyObject = GetComponent <Enemy>(); _tree = BLStandardAI.InstantiateTree(BLStandardAI.TreeType.Enemies_BuzzSaw, this); while (Application.isPlaying && _tree != null) { AIUpdate(); yield return(new WaitForSeconds(1 / _tree.Frequency)); } }
public static BehaveResult UnhandlesID(int id) { if (BLStandardAI.IsAction(id)) { Debug.LogError("Unhandled Action: " + ((BLStandardAI.ActionType)id).ToString()); } else if (BLStandardAI.IsDecorator(id)) { Debug.LogError("Unhandled decorator: " + ((BLStandardAI.DecoratorType)id).ToString()); } else { Debug.LogError("Invalid ID: " + id); } return(BehaveResult.Success); }