2

Currently, the scripting backend is IL2CPP. I need to change it to .NET. I am not sure why it is disabled.

screenshot of player setting

I tried to add component via Unity Hub. It doesn't have Add component option and there was no option in Unity Installer as well.

screenshot of Unity Installer

How do I change it to .NET?

Community
  • 1
  • 1
MrRobot9
  • 2,402
  • 4
  • 31
  • 68

1 Answers1

3

You can't

Per the documentation Unity deprecated the .NET backend and only IL2CPP remains.

Note: The .NET scripting backend is deprecated and will be removed in a future release of Unity. We recommend switching to the IL2CPP scripting backend.

Given that that page is for Unity 2018.2 the feature has been removed in Unity 2019, which the current documentation page supports.

L2CPP is the only scripting back end supported for building projects for Universal Windows Platform.

Any other references saying that UWP supports a .NET backend haven't been updated to reflect this change.

See also this Microsoft MR issue on GitHub.

  • So, will deploying to Hololens work with this scripting end or do I need to install older Unity versions – MrRobot9 Oct 07 '19 at 18:51
  • Based on [the issue on GitHub](https://github.com/MicrosoftDocs/mixed-reality/issues/490), it looks like you will need to use an older version of Unity, as the most recent comment (Dec '18) on that issue states that they are unable to build using IL2CPP. I recommend also filing a bug report with Unity. – Draco18s no longer trusts SE Oct 07 '19 at 18:52
  • 1
    Not true, you [can build to HoloLens (UWP) using IL2CPP](https://docs.unity3d.com/Manual/windowsstore-il2cpp.html) without any problems. We do it all the time. Nothing really changes except the [Debugging process](https://blogs.msdn.microsoft.com/appconsult/2018/11/08/how-to-debug-unity-projects-with-il2cpp-backends-on-the-hololens/). But building and deployment is done just as before - using .Net - via VisualStudio – derHugo Oct 08 '19 at 06:19
  • Thanks for those resources @derHugo, but I haven't worked with the hololens since 2016. – Draco18s no longer trusts SE Oct 08 '19 at 12:40
  • @derHugo what version of unity are you using ? I am having similar issues on 2021.1.14. Trying to build for the hololens 2. Error is C++ code builder is unable to build C++ code. In order to build C++ code for Universal Windows Platform. Something to do with the scripting backend highlighted on the post. – Tonderai Ratisai Nov 21 '21 at 22:01