Jival pal
Jival pal

Reputation: 41

visual studio code intellisense not working(mac)

after opening the C# project I get

fail]: OmniSharp.MSBuild.ProjectManager
        Attempted to update project that is not loaded: Desktop/UNITY STUFF/action platformer/Assembly-CSharp.csproj
[fail]: OmniSharp.MSBuild.ProjectManager
        Attempted to update project that is not loaded: Desktop/UNITY STUFF/action platformer/Assembly-CSharp-Editor.csproj

does anyone have a solution? thanks in advance

Upvotes: 4

Views: 9325

Answers (3)

Raghav Arora
Raghav Arora

Reputation: 29

For all the people that are using newer versions of vs code and don't find the above settings, here's what you need to do:

  1. Uncheck "Omnisharp: Use modern .NET"
  2. A popup should appear in vs code to download mono (if it dosn't, download it manually from [https://www.mono-project.com/download/stable/][1]
  3. restart Visual Studio Code (Cmd + Q and then re-open)

Upvotes: 2

Vasil3
Vasil3

Reputation: 110

Close Visual Studio. In Unity go to Edit < Preferences < External Tools And make sure External Script Editor is Visual Studio so that additional checkboxes appear.

Make sure Generate all csproj files is checked, and Editor Attaching is checked

On MacOS: Check all checboxes. Click "Regenerate project files".

You may need to close and reopen Visual Studio.

Upvotes: 4

Akhrorjon
Akhrorjon

Reputation: 154

I solved this issue by doing the following on VSCode:

  • Go to settings. (Code -> Preferences -> Settings on Mac)
  • Search "omnisharp".
  • Find the section "Omnisharp: Use Global Mono," and set it to "always."
  • Find the section "Omnisharp: Path," and click "Edit in settings.json."
  • Change "omnisharp.path" as "omnisharp.path": latest".
  • Reload the window.

Original answer is here: https://stackoverflow.com/a/63603883/9337700

Upvotes: 0

Related Questions