示例#1
0
        public override MoveState GetState(HumanoidMoveStateMachine self, Vector3 moveInput)
        {
            MoveState state;

            if (self.isJumping)
            {
                state = jumpState;
            }
            else if (moveInput == Vector3.zero)
            {
                state = idleState;
            }
            else if (self.isRunning)
            {
                state = runState;
            }
            else
            {
                state = walkState;
            }

            return(state);
        }
 public override MoveState GetState(HumanoidMoveStateMachine self, Vector3 moveInput)
 {
     return(moveInput == Vector3.zero ? idleState : walkState);
 }
 public abstract MoveState GetState(HumanoidMoveStateMachine self, Vector3 moveInput);