Script not working even though there are no bugs

I’m following this guy’s tutorial on First Person Controller

and my PlayerMove script isn’t working. I brang this issue to different people and there are no bugs but nobody could find the problem. Any help?

using UnityEngine;
using System.Collections;

public class PlayerMove : MonoBehaviour{
        [SerializeField] private string horizontalInputName;
        [SerializeField] private string verticalInputName;
        [SerializeField] private float movementSpeed;

        private CharacterController charController;

        private void Awake()
        {
            charController = GetComponent<CharacterController>();
        }

        private void Update()
        {
            PlayerMovement();
        }

        private void PlayerMovement()
        {
            float horizInput = Input.GetAxis (horizontalInputName) * movementSpeed;
            float vertInput = Input.GetAxis(verticalInputName) * movementSpeed;   

            Vector3 forwardMovement = transform.forward * vertInput;
            Vector3 rightMovement = transform.right * horizInput;

            charController.SimpleMove(forwardMovement + rightMovement);
           
        }
}

What does “isn’t working” mean?
What values have you set for the 3 fields?
Have you verified that the input manager has axis with the exact names as you used in those fields?
Do you have any console errors?

Otherwise, add debugging to output the values of the vertical and horizontal axis you are using.

I mean that the character isn’t moving.
Which 3 fields?
The input manager has it set as Horizontal and Vertical, but as i was checking in input manager the type for both Horizontal and Vertical are set to “Joystick Axis” but I am using keyboard buttons. Is this part of the problem?

The console errors are for the Plane 3D Object i put in, but it says: The referenced script on this Behaviour is missing! and The referenced script on this Behaviour (Game Object ‘Plane’) is missing!

Your script has horizontalInputName and verticalInputName which will be blank in the inspector until you type in the exact name of the input axis you want to use for each. Without these your script won’t actually take any input.

Your script also has a field movementSpeed which you need to set a value greater than 0f, since the input axis is multiplied by this value to determine how much movement. Floats will default to 0f if you don’t set them to something, and if movementSpeed is left at 0f then you will always result in movement of 0 no matter the value coming from either input axis.

It is possible to use keyboard buttons as part of an input manager axis. Though personally I prefer to just check for keyboard input directly instead of using an axis in that case. YMMV

Oh, I literally just figured out that my movement speed on the component wasn’t set to anything. Whoopsies.