Home > Enterprise >  Unity/C# autocomplete not working in Visual Studio Code for Linux with .NET version 6.x
Unity/C# autocomplete not working in Visual Studio Code for Linux with .NET version 6.x

Time:03-04

I can't get IntelliSense in to autocomplete or show suggestions for Unity (20.3.30 LTS) methods in Visual Studio Code in Linux (Ubuntu 20.04). I have downloaded .NET version 6.0.102 on my Ubuntu but the Unity API Compatibility Level only goes as high as 4.x, which is subsequently no longer available for download on Linux... Does anyone have a solution to this problem, or maybe a suggestion on what else to do (maybe use a different IDE)?

CodePudding user response:

Something that worked for me in the end was to add

"omnisharp.path": "latest",
"omnisharp.useGlobalMono": "always"

in the settings.json file of Visual Studio Code. It still started complaining after that and it turned out that I needed to install Mono still. I did that by running

sudo apt install mono-complete

in the terminal after which I restarted omnisharp and everything worked like a charm.

  • Related