//--------------------------------------------------------------------- public BehaviorComponent(BehaviorTree bt) { mBehaviorTree = bt; }
//--------------------------------------------------------------------- // Selects among the given behavior components // Performs an OR-Like behavior and will "fail-over" to each successive component until Success is reached or Failure is certain // -Returns Success if a behavior component returns Success // -Returns Running if a behavior component returns Running // -Returns Failure if all behavior components returned Failure public Selector(BehaviorTree bt, params BehaviorComponent[] behaviors) : base(bt) { _Behaviors = behaviors; }