C
C#5mo ago
Mathis NSM

All compiler errors have to be fixed before you can enter playmode!

I have an error with Unity, I made a script and it gives me an error when I do “Play” can anyone help me please?
5 Replies
Mathis NSM
Mathis NSMOP5mo ago
c#
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class NewBehaviourScript : MonoBehaviour
{
// Start is called before the first frame update
void Start()
{
Debug.log("Hello, World!");
}

// Update is called once per frame
void Update()
{

}
}
c#
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class NewBehaviourScript : MonoBehaviour
{
// Start is called before the first frame update
void Start()
{
Debug.log("Hello, World!");
}

// Update is called once per frame
void Update()
{

}
}
Buddy
Buddy5mo ago
C# is case sensitive log is not a valid function I recommend you learn C# before using Unity if you don't know C#. $helloworld
Mathis NSM
Mathis NSMOP5mo ago
Okay thx u I watched a video on youtube and in the video it worked..
Buddy
Buddy5mo ago
Watch closely as I mentioned above, C# is a case sensitive language which means log and Log can be two entirely different functions Methods in C# generally follow PascalCase, which means first letter in each word is always uppercase. YourNameHere is PascalCase Please don't follow youtube tutorials, it will only make you stuck in tutorial hell where you can only make games by following tutorials and not experimenting on your own.
Want results from more Discord servers?
Add your server