Animator is not working

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[System.Serializable]
public enum SIDE {Left, Mid, Right}
public class PlayerMove : MonoBehaviour
{
public SIDE m_side = SIDE.Mid;
float NewXpos = 0f;
[HideInInspector]
public bool SwipeLeft, SwipeRight;
public float XValue;
private CharacterController m_char;
private Animator m_animator;
private float x;
public float speeddodge;

void Start()
{
    m_char = GetComponent<CharacterController>();
    m_animator =  GetComponent<Animator>();
}
void Update()
{
    SwipeLeft = Input.GetKeyDown(KeyCode.A) || Input.GetKeyDown(KeyCode.LeftArrow);
    SwipeRight = Input.GetKeyDown(KeyCode.D) || Input.GetKeyDown(KeyCode.RightArrow);
    if (SwipeLeft)
    {
        if(m_side == SIDE.Mid)
        {
            NewXpos = -XValue;
            m_side = SIDE.Left;
           m_animator.Play("Standing Dodge Left");
        }else if(m_side == SIDE.Right)
        {
            NewXpos = 0;
            m_side = SIDE.Mid;
            m_animator.Play("Standing Dodge Left");
        }
    }
    else if (SwipeRight)
    {
        if (m_side == SIDE.Mid)
        {
            NewXpos = XValue;
            m_side = SIDE.Right;
            m_animator.Play("Standing Dodge Right");
        }
        else if (m_side == SIDE.Left)
        {
            NewXpos = 0;
            m_side = SIDE.Mid;
          m_animator.Play("Standing Dodge Right");
        }
    }
    x = Mathf.Lerp(x, NewXpos, Time.deltaTime * speeddodge );
    m_char.Move((x -transform.position.x)*Vector3.right);
    
}  

}

Honestly it’s difficult to tell since you just provided a script and didn’t tell us any context on how it’s not working, what you’ve checked already, or even if there are any error messages.

However I recommend you use parameters in your animator instead of using Animator.Play().

An example of a parameter you could set up is a bool called “didSwipeRight”.
Have it set to false by default.

Then in your Animator’s state transitions, you can set it up so that there’s a transition from “Standing” to “Standing Dodge Right” if “didSwipeRight” is true.

Then when you detect a swipe right was done you could call this:

Animator.SetBool("didSwipeRight", true);

Which will trigger the animation since you have a transition set up for it.