示例#1
0
 public bool OnJointBreak2D(Joint2D joint)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoJointBreak2D(joint);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#2
0
 public bool OnTriggerExit2D(Collider2D other)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoTriggerExit2D(other);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#3
0
 public bool OnControllerColliderHit(ControllerColliderHit collider)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoControllerColliderHit(collider);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#4
0
 public bool OnCollisionExit2D(Collision2D collisionInfo)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoCollisionExit2D(collisionInfo);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#5
0
 public bool OnParticleCollision(GameObject other)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoParticleCollision(other);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#6
0
 public bool OnAnimatorIK(int layerIndex)
 {
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.DoAnimatorIK(layerIndex);
     }
     this.RemoveFinishedActions();
     return(this.fsm.IsSwitchingState);
 }
示例#7
0
        public bool OnEvent(SkillEvent fsmEvent)
        {
            bool flag = false;

            for (int i = 0; i < this.ActiveActions.get_Count(); i++)
            {
                SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
                fsmStateAction.Init(this);
                flag = fsmStateAction.Event(fsmEvent);
            }
            return(this.fsm.IsSwitchingState || flag);
        }
示例#8
0
 public void OnUpdate()
 {
     if (this.finished)
     {
         return;
     }
     this.StateTime += Time.get_deltaTime();
     for (int i = 0; i < this.ActiveActions.get_Count(); i++)
     {
         SkillStateAction fsmStateAction = this.ActiveActions.get_Item(i);
         fsmStateAction.Init(this);
         fsmStateAction.OnUpdate();
     }
     this.CheckAllActionsFinished();
 }
示例#9
0
 public void OnExit()
 {
     this.active   = false;
     this.finished = false;
     SkillStateAction[] array = this.Actions;
     for (int i = 0; i < array.Length; i++)
     {
         SkillStateAction fsmStateAction = array[i];
         if (fsmStateAction.Entered)
         {
             this.activeAction = fsmStateAction;
             fsmStateAction.Init(this);
             fsmStateAction.OnExit();
         }
     }
 }