Hello guys,
maybe it is not the right place to put this question, but i am new so forgive me, I encounter this error:
i just create a new UNITY project (ver. 2019.2.17f1)
then i create a new C# script in Assets window keeping it with the default name “NewBehaviourScript”
well it comes with already an error: “No MonoBehaviour scripts in the file, or name not match filename” (second option obvously not the case)
Do I have to import any package or some extra Assets to include all the dependencies and ged able to get MonoBehaviour?
Thank you very much
PS my PC language is french so i dont know if something is connected to this.
Ok i thought the content of file was ininfluent cause it is the automated one created by unity…
My system spec are: Windows 7 SP1 - 64bit CPU AMD AThlon 3.40 Ghz - 6Gb memory
i just create a new UNITY project (ver. 2019.2.17f1) from UNITY Hub 3D template after opening UNITY i right click on Assets and create C# script and this is what is automatically created (imported object: NewBehaviourScript )
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NewBehaviourScript : MonoBehaviour
{
// Start is called before the first frame update
void Start()
{ }
// Update is called once per frame
void Update()
{ }
}
What IDE i do use is it important? I am just creating a script in unity interface… anyway it downloaded and installed visual studio 2019, and yes i restarted PC and tried creating new project or reloading the new saved with no results, i am now trying to install a older version of unity maybe it will change something…
Man, I didn’t mean disrespect or complain, sorry to sound like that. And yes i read that page you linked there.
I am sure it is about Visual Studio settings or installation because i just installed UNITY and creating an empty C# Asset it was the first thing i have done in it…
I notice that VisualStudio has been installed in french
installed Unity 2018.4.14f1 (64-bit) with VisualStudio 2018 same result.
Thanks to help me understand that the message I get in UNITY interface about the script error is coming from the IDE and not UNITY itself.
Game Development with Unity must be installed in Visual Studio; it should have been installed already if you installed Visual Studio Community by adding the module in the Hub. The language you use is irrelevant.