Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

The type or namespace name 'Vectore3' could not be found (are you missing a using directive or an assembly reference?)

I am currently following a tutorial on YouTube to make a FirstPerson Movement and get this error in Unity: Assets\Scripts\PlayerMovment\PlayerMovment.cs(13,5): error CS0246: The type or namespace name ’Vectore3′ could not be found (are you missing a using directive or an assembly reference?). Can someone help me?
Here’s the code:

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

public class NewBehaviourScript : MonoBehaviour
{
    [Header("Movment")]
    public float moveSpeed = 5f;

    float horizontalMovement;
    float verticalMovement;

    Vectore3 moveDirection;

    Rigidbody rb;

    private void Start(){
        rb = GetComponent<Rigidbody>();
        rb.freezeRotation = true;
    }

    private void Update(){
        MyInput();
    }

    void MyInput(){
        horizontalMovement = Input.GetAxisRaw("Horizontal");
        verticaMovement = Input.GetAxisRaw("Vertical");

        moveDirection = transform.forward * verticalMovement + transform.right * horizontalMovement;
    }

    private void FixedUpdate(){
        MovePlayer();
    }

    void MovePlayer(){
        rb.AddForce(moveDirection.normalized * moveSpeed, ForceMode.Acceleration);
    }
}

>Solution :

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

I believe this is down to a typo. Vectore3 should read Vector3.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading