void HandleStateChanged()
        {
            // When the state changes, notify the animation handle of the new state.
            string stateName = null;

            switch (currentState)
            {
            case CharacterState.Idle:
                stateName = "idle/f_l_idle";
                break;

            case CharacterState.Walk_Up:
                stateName = "walk/b_r_walk";
                break;

            case CharacterState.Walk_Down:
                stateName = "walk/f_l_walk";
                break;

            case CharacterState.Walk_Left:
                stateName = "walk/f_l_walk";
                break;

            case CharacterState.Walk_Right:
                stateName = "walk/b_r_walk";
                break;

            default:
                break;
            }

            animationHandle.PlayAnimationForState(stateName, 0);
        }
        override public void OnStateEnter(Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
        {
            if (!initialized)
            {
                animationHandle = animator.GetComponent <SkeletonAnimationHandleExample>();
                initialized     = true;
            }

            animationHandle.PlayAnimationForState(stateInfo.shortNameHash, layerIndex);
        }
        // 改变动画状态
        void HandleStateChanged()
        {
            // 状态更改时,将新状态通知动画处理器。
            string stateName = null;

            switch (currentState)
            {
            case CharacterState.Idle:                    // 角色状态
                stateName = "idle";
                break;

            case CharacterState.Walk:
                stateName = "walk";
                break;

            case CharacterState.Run:
                stateName = "run";
                break;

            case CharacterState.Crouch:
                stateName = "crouch";
                break;

            case CharacterState.Rise:
                stateName = "rise";
                break;

            case CharacterState.Fall:
                stateName = "fall";
                break;

            case CharacterState.Attack:
                stateName = "attack";
                //Animation a = animationHandle.GetAnimationForState(stateName);
                //animationHandle.PlayOneShot(a, 0);
                //return;
                break;

            default:
                break;
            }

            animationHandle.PlayAnimationForState(stateName, 0);// 播放状态的动画
        }
        void HandleStateChanged()
        {
            // When the state changes, notify the animation handle of the new state.
            string stateName = null;

            switch (currentState)
            {
            case CharacterState.Idle:
                stateName = "idle";
                break;

            case CharacterState.Walk:
                stateName = "walk";
                break;

            case CharacterState.Run:
                stateName = "run";
                break;

            case CharacterState.Crouch:
                stateName = "crouch";
                break;

            case CharacterState.Rise:
                stateName = "rise";
                break;

            case CharacterState.Fall:
                stateName = "fall";
                break;

            case CharacterState.Attack:
                stateName = "attack";
                break;

            default:
                break;
            }

            animationHandle.PlayAnimationForState(stateName, 0);
        }