Is Visual Studio Mandatory to use Unity?

Hi, I’ve used Unity for several months and used Visual Studio Code as the code editor. Recently I found out that Unreal engine uses Visual Studio Compiler and requires Visual Studio Community and up. Now, I’m curious if Unity also requires Visual Studio Community and up to compile the project and release. Thank you!

No, Unity uses Mono to compile your C# code. Mono is shipped with Unity and part of the editor / engine. You can write your scripts in notepad if you like.

It’s actually a common misconception. Even Unity creates a solution and “csproj” file for your project, it is not used by Unity at all. It’s just generated to have better IDE support. Unity always compiles your scripts with a custom command line. So all settings inside the csproj file are ignored. That’s why adding references to other assemblies inside Visual Studio has no effect in Unity.