IIRC it uses Mono unless your build target is set to Windows Store.
-
no, that’s the library, not the runtime. You’ll still be using the mono runtime in Unity (with some some exceptions, where platforms like mobile have weird technicalities)
-
Yes, it is possible to use the various System libraries in unity.
-
The solution/project that is generated by unity allows reference to all the libraries that are valid to be used in unity. If you change your platform in the build settings, you will get warnings, since some platforms have restrictions (like mobile).
That is to say, there are still some features that might not throw warnings until runtime. Like System.Reflection.Emit on mobile. Or certain combinations of generics that don’t compile well for AOT for webgl and iOS.
But how does Unity know if I’m referencing .net or mono with my using System.something statement?
Sry I don’t undertsand that at the moment.
It’s all Mono, but you shouldn’t technically see any difference in the code except that not all of System is available in Mono.
That means I don’t know if I use .net until I try to build and get a warning? Can I restrict my development somehow to mono even if .net is installed?
mono has its own System library, which is an opensource reimplementation of the .net one.
The compiler knows which it’s referencing.
And in the case of unity, the compiler is referencing the mono version of System.dll and mscorlib.dll
And since they’re dynamically loaded, if you include a .net compiled library in your project that references System.dll, and it has the mono version of the System.dll loaded already, it’ll use that.
ok thank you no more questions at the moment 