Certainly for me C# is “the Unity language.” I’m dimly aware that it has some vague Microsoft association, but I don’t think I’ve even seen a piece of MS tooling for it in…many years. Unity + JetBrains Rider has been a pleasant gamedev environment.
Certainly for me C# is “the Unity language.” I’m dimly aware that it has some vague Microsoft association, but I don’t think I’ve even seen a piece of MS tooling for it in…many years. Unity + JetBrains Rider has been a pleasant gamedev environment.
It's unfortunate that they're still stuck on their old fork of Mono, because Microsoft's tooling (and their runtime) is really good. You can write a C# game in Godot now and seamlessly use the Visual Studio debugger without any janky plugin.
Didn't they switch to .NET Core years ago? Of course for many platforms you have to use their CPP transpiler which complicates some things that might be possible in normal C#.
Unity currently does not support .NET (Core) at all.
Most modern large games use IL2CPP, the C++ transpiler; it's a requirement on iOS, nearly a requirement on Android, and almost certainly a requirement on consoles. Perf is often nicer and it's harder to mod/hack, which some devs like.
Sibling poster notes different .Net compatibility settings. Modern Unity versions allow you to be in either .Net 4.6(ish) mode or .Net Standard 2.0/2.1 mode. The latter comports more with Core's APIs, though is pretty old at this point.
And, since we're on similar topics, Unity currently supports C# 9.0, minus a few minor features[1]. This is a massive improvement compared to a few years ago, where we were stuck with C# 4 or 6, and means you can write pretty modern and performant C#. Especially notable is Span support, a way of representing (basically) non-owning array slices.
[1] https://docs.unity3d.com/2023.3/Documentation/Manual/CSharpC...
Nowadays DirectX team doesn't even bother to shy away from it, it is up to Unity or other third parties to provide bindings to .NET.
Compare this with Swift bindings to Metal, or Java ones to OpenGL ES (Android might also get WebGPU bindings to Java, lets see what Android 15 brings).