Ejemplo n.º 1
0
 public override void OnValidate(Graph assignedGraph)
 {
     if (_onEnterList == null){
         _onEnterList = (ActionList)Task.Create(typeof(ActionList), assignedGraph);
         _onEnterList.executionMode = ActionList.ActionsExecutionMode.ActionsRunInParallel;
     }
     if (_onUpdateList == null){
         _onUpdateList = (ActionList)Task.Create(typeof(ActionList), assignedGraph);
         _onUpdateList.executionMode = ActionList.ActionsExecutionMode.ActionsRunInParallel;
     }
     if (_onExitList == null){
         _onExitList = (ActionList)Task.Create(typeof(ActionList), assignedGraph);
         _onExitList.executionMode = ActionList.ActionsExecutionMode.ActionsRunInParallel;
     }
 }
 ////////////////////////////////////////
 ///////////GUI AND EDITOR STUFF/////////
 ////////////////////////////////////////
 void Reset()
 {
     var bb = GetComponent<Blackboard>();
     _blackboard = bb != null? bb : gameObject.AddComponent<Blackboard>();
     _actionList = (ActionList)Task.Create(typeof(ActionList), this);
 }