protected virtual void TriggerAnimation()
        {
            if (debugMode)
            {
                Debug.Log("TriggerAnimation");
            }

            // trigger the animation behaviour & match target
            if (!string.IsNullOrEmpty(triggerAction.playAnimation))
            {
                isPlayingAnimation = true;
                tpInput.cc.animator.CrossFadeInFixedTime(triggerAction.playAnimation, 0.1f);    // trigger the action animation clip
            }

            // trigger OnDoAction Event, you can add a delay in the inspector
            StartCoroutine(triggerAction.OnDoActionDelay(gameObject));

            // bool to limit the autoAction run just once
            if (triggerAction.autoAction || triggerAction.destroyAfter)
            {
                triggerActionOnce = true;
            }

            // destroy the triggerAction if checked with destroyAfter
            if (triggerAction.destroyAfter)
            {
                StartCoroutine(DestroyDelay(triggerAction));
            }
        }
        public virtual void TriggerAnimation()
        {
            if (playingAnimation || actionStarted)
            {
                return;
            }
            doingAction = true;
            OnDoAction.Invoke(triggerAction);

            //triggerAction.OnPlayerExit.Invoke();
            if (debugMode)
            {
                Debug.Log("TriggerAnimation", gameObject);
            }

            if (triggerAction.animatorActionState != 0)
            {
                if (debugMode)
                {
                    Debug.Log("Applied ActionState: " + triggerAction.animatorActionState, gameObject);
                }
                tpInput.cc.SetActionState(triggerAction.animatorActionState);
            }

            // trigger the animation behaviour & match target
            if (!string.IsNullOrEmpty(triggerAction.playAnimation))
            {
                if (!actionStarted)
                {
                    actionStarted    = true;
                    playingAnimation = true;
                    tpInput.cc.animator.CrossFadeInFixedTime(triggerAction.playAnimation, 0.1f);    // trigger the action animation clip
                    if (!string.IsNullOrEmpty(triggerAction.customCameraState))
                    {
                        tpInput.ChangeCameraState(triggerAction.customCameraState, true);                 // change current camera state to a custom
                    }
                }
            }
            else
            {
                actionStarted = true;
            }
            animationBehaviourDelay = 0.2f;
            // trigger OnDoAction Event, you can add a delay in the inspector
            StartCoroutine(triggerAction.OnDoActionDelay(gameObject));
            // destroy the triggerAction if checked with destroyAfter
            if (triggerAction.destroyAfter)
            {
                StartCoroutine(DestroyActionDelay(triggerAction));
            }
        }