i have there errors can u help?

Assets\PlayerManager.cs(11,37): error CS0246: The type or namespace name ‘Inputmanagar’ could not be found (are you missing a using directive or an assembly reference?)

Assets\PlayerManager.cs(17,22): error CS1061: ‘InputManagar’ does not contain a definition for ‘HandleAllInputs’ and no accessible extension method ‘HandleAllInputs’ accepting a first argument of type ‘InputManagar’ could be found (are you missing a using directive or an assembly reference?)

Assets\playerlocomotion.cs(32,61): error CS1061: ‘InputManagar’ does not contain a definition for ‘verticalInput’ and no accessible extension method ‘verticalInput’ accepting a first argument of type ‘InputManagar’ could be found (are you missing a using directive or an assembly reference?)

Assets\playerlocomotion.cs(33,75): error CS1061: ‘InputManagar’ does not contain a definition for ‘horizontalInput’ and no accessible extension method ‘horizontalInput’ accepting a first argument of type ‘InputManagar’ could be found (are you missing a using directive or an assembly reference?)

Assets\playerlocomotion.cs(46,63): error CS1061: ‘InputManagar’ does not contain a definition for ‘verticalInput’ and no accessible extension method ‘verticalInput’ accepting a first argument of type ‘InputManagar’ could be found (are you missing a using directive or an assembly reference?)

Assets\playerlocomotion.cs(47,79): error CS1061: ‘InputManagar’ does not contain a definition for ‘horizontalInput’ and no accessible extension method ‘horizontalInput’ accepting a first argument of type ‘InputManagar’ could be found (are you missing a using directive or an assembly reference?)

this is my player locomotion code

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerLocomotion : MonoBehaviour
{
    InputManagar inputManagar;

    Vector3 moveDirection;
    Transform cameraObject;
    Rigidbody playerRigidbody;

    public float movementSpeed = 7;
    public float rotationSpeed = 15;

    private void Awake()
    {
        inputManagar = GetComponent<InputManagar>();
        playerRigidbody = GetComponent<Rigidbody>();
        cameraObject = Camera.main.transform;
    }
   
    public void HandleAllMovement()
    {
        HandleMovement();
        HandleRotation();
    }


    private void HandleMovement()
    {
        moveDirection = cameraObject.forward * inputManagar.verticalInput;
        moveDirection = moveDirection + cameraObject.right * inputManagar.horizontalInput;
        moveDirection.Normalize();
        moveDirection.y = 0;
        moveDirection = moveDirection * movementSpeed;

        Vector3 movementVelocity = moveDirection;
        playerRigidbody.velocity = movementVelocity;
    }

    private void HandleRotation()
    {
        Vector3 targetDirection = Vector3.zero;

        targetDirection = cameraObject.forward * inputManagar.verticalInput;
        targetDirection = targetDirection + cameraObject.right * inputManagar.horizontalInput;
        targetDirection.Normalize();
        targetDirection.y = 0;

        Quaternion targetRotation = Quaternion.LookRotation(targetDirection);
        Quaternion playerRotation = Quaternion.Slerp(transform.rotation, targetRotation, rotationSpeed * Time.deltaTime);

        transform.rotation = playerRotation;
    }
}

and this is my input managar code

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class InputManagar : MonoBehaviour
{
    PlayerControls playerControls;

    public Vector2 movementInput;
    public float verticalInput;
    public float horizontalInput;

    private void OnEnable()
   {
    if (playerControls == null)
    {
            playerControls = new PlayerControls();

             playerControls.PlayerMovement.Movement.performed += i => movementInput = i.ReadValue<Vector2>();
    }
        playerControls.Enable();

   }   
    private void OnDisable()
    {
        playerControls.Disable();
    }

    public void HandleAllInputs()
    {
        HandleMovementInput();
        //jump acction
    }

    private void  HandleMovementInput()
    {
        verticalInput = movementInput.y;
        horizontalInput = movementInput.x;
    }
}

thanls

Remember: NOBODY memorizes error codes. The error code is absolutely the least useful part of the error. It serves no purpose at all. Forget the error code. Put it out of your mind.

The important parts of an error message are:

  • the description of the error itself (google this; you are NEVER the first one!)
  • the file it occurred in (critical!)
  • the line number and character position (the two numbers in parentheses)

All of that information is in the actual error message and you must pay attention to it. Learn how to identify it instantly so you don’t have to stop your progress and fiddle around with the forum.

How to understand compiler and other errors and even fix them yourself:

Please don’t create multiple threads for one similar issue.

Your first error is you have to capitalize things correctly, probably, because you didn’t post that script. Don’t know about the 2nd error since again you didn’t post that script. The later errors look like you’ve posted a different version of the script than what the errors are for.

Whoa, seriously… this is the THIRD post OP has made for the same set of lazy typographic errors.

This is software engineering. Every single character has to be typed PRECISELY the way it should be.

That means perfect spelling, perfect capitalization, perfect punctuation, and perfect spacing (or lack thereof).

That’s just mandatory, not open to discussion or negotiation.

Once you have that part done, then you can begin engineering the actual problem.

Please stop posting duplicate threads for simple fat-finger typos.

3 Likes

You need to read the rules before you post again. These are low effort and unclear posts. See other’s responses to you. READ the warnings, they tell you your problems. This forums is not just for posting errors without context and expecting others to do your work for you. Additional posts of this nature will result in formal warnings which can lead to restrictions on using this forum.