Print function in Unity monobehavier - Confused

I have learned a little in c sharp. But My question is in the tutorial of making 2d games unity. Sir tells to write helloworld. So he write print(“helloworld”); which is working, and I can see the message in unity console. But as in c sharp we use System.Console.WriteLine(“helloworld”); which is not working in unity console.

Can anyone tell me, Does unity use different functions? anything related to this as I am really confused.

Hi,

Yes, Unity uses different classes and functions. C# is just the language. Not everything works in every framework/environment.

System.Console refers to the Windows terminal. Unity has nothing to do with Windows.

Did this help?

1 Like

Thanks Nina, But where can I find all the list of Unity Functions so i can read it. Please help me out.

Take a look at the Unity API. There are probably all classes, functions and properties listed.

https://docs.unity3d.com/ScriptReference/

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms