I have multiple projects.
Project A was started a month or so ago, in an older version of unity without the prefab updates.
Project B i started today.
I updated my Unity, when i hadn’t updated it in a while (4 or 5 months).
Project A now works with intellisense (autocompletion), has the new features of the update (new prefabs) etc.
Project B and any other projects that i start after updating now do not have intellisense working.
When i create new scripts in new projects and open them in visual studio code, i get the ‘Some projects have trouble loading. Please review the output for more details (Source: C# Extension)’ Error.
In the output it says visual studio code:
Starting OmniSharp server at 2/6/2019, 9:54:12 PM
Target: e:\Game creation\Shapes\Shapes.sln
OmniSharp server started.
Path: C:\Users\Emolk\.vscode\extensions\ms-vscode.csharp-1.17.1\.omnisharp\1.32.8\OmniSharp.exe
PID: 4504
[info]: OmniSharp.Stdio.Host
Starting OmniSharp on Windows 6.1.7601.65536 (x64)
[info]: OmniSharp.Services.DotNetCliService
DotNetPath set to dotnet
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
Located 2 MSBuild instance(s)
1: Visual Studio Community 2017 15.6.27428.2015 - "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin"
2: StandAlone 15.0 - "C:\Users\Emolk\.vscode\extensions\ms-vscode.csharp-1.17.1\.omnisharp\1.32.8\msbuild\15.0\Bin"
[info]: OmniSharp.MSBuild.Discovery.MSBuildLocator
Registered MSBuild instance: Visual Studio Community 2017 15.6.27428.2015 - "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin"
[info]: OmniSharp.Cake.CakeProjectSystem
Detecting Cake files in 'e:\Game creation\Shapes'.
[info]: OmniSharp.Cake.CakeProjectSystem
Could not find any Cake files
[info]: OmniSharp.WorkspaceInitializer
Project system 'OmniSharp.DotNet.DotNetProjectSystem' is disabled in the configuration.
[info]: OmniSharp.MSBuild.ProjectSystem
Detecting projects in 'e:\Game creation\Shapes\Shapes.sln'.
[info]: OmniSharp.MSBuild.ProjectManager
Queue project update for 'e:\Game creation\Shapes\Assembly-CSharp.csproj'
[info]: OmniSharp.Script.ScriptProjectSystem
Detecting CSX files in 'e:\Game creation\Shapes'.
[info]: OmniSharp.Script.ScriptProjectSystem
Could not find any CSX files
[info]: OmniSharp.WorkspaceInitializer
Invoking Workspace Options Provider: OmniSharp.Roslyn.CSharp.Services.CSharpWorkspaceOptionsProvider
[info]: OmniSharp.WorkspaceInitializer
Configuration finished.
[info]: OmniSharp.Stdio.Host
Omnisharp server running using Stdio at location 'e:\Game creation\Shapes' on host 6680.
[info]: OmniSharp.MSBuild.ProjectManager
Loading project: e:\Game creation\Shapes\Assembly-CSharp.csproj
[fail]: OmniSharp.MSBuild.ProjectLoader
The reference assemblies for framework ".NETFramework,Version=v4.7.1" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.
[warn]: OmniSharp.MSBuild.ProjectManager
Failed to load project file 'e:\Game creation\Shapes\Assembly-CSharp.csproj'.
e:\Game creation\Shapes\Assembly-CSharp.csproj
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1126,5): Error: The reference assemblies for framework ".NETFramework,Version=v4.7.1" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.
[fail]: OmniSharp.MSBuild.ProjectManager
Attemped to update project that is not loaded: e:\Game creation\Shapes\Assembly-CSharp.csproj
Changing to visual studio community 2017 in preferences and opening the script gives me this:
This is extremely annoying and has stopped me working all day. Any help would be appreciated.
Intellisense works ONLY in Visual studio 2015, however i much prefer visual studio code to work with.
I have tried reinstalling .NET, unity and visual code to no avail.