I have just got back into game making with unity after a one year break, and after installing unity hub 3.0, unity 2020 (the recommended version) and visual studio 2022. I attempted making a script and noticed that intellisense wasn’t working in visual studio, so I tried closing visual studio and re opening the script (which automatically opens visual studio), but I got an error message saying that one or more files failed to load (which ended up being Assembly-Csharp). I’ve tried many things that I’ve seen online like right clicking it and clicking reload, deleting and regenerating the files, and deleting and reinstalling Assembly-Csharp through unity, but nothing has worked.
It seems that the issue is that visual studio cant load any .csproj files (I tried regenerating all possible .csproj files in unity but visual studio couldn’t read any of them), which puts all the .cs files into ‘miscellaneous files’ meaning intellisense wasn’t working for them. I have also tried using unity 2019 (what i used to use) and visual studio 2019, but the same issue still applied.
this seems to happen even when creating a new unity project or even deleting unity and visual studio and reinstalling them.
Does anyone know how I could fix this?
here is the error message (using unity 2020 and visual studio 2019 for this one):
C:\Users\jacqui\OneDrive\Desktop\unity_games\test\Assembly-CSharp.csproj : error : The imported project “C:\Users\jacqui\OneDrive\Desktop\unity_games\test\obj\Assembly-CSharp.csproj..props" was not found. Confirm that the expression in the Import declaration "C:\Users\jaken\OneDrive\Desktop\unity_games\test\obj\Assembly-CSharp.csproj..props” is correct, and that the file exists on disk. C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Microsoft.Common.props
