How do I make VS 2015 auto-complete my C# code in Unity?

Hey, for some reason Visual Studio no longer autocompletes code from Unity, such as GameObject or getcomponent.

I tried in monodevelop and here it still works, but just in VS it doesn’t auto-complete for me anymore which is really annoying since I like VS and hate Monodevelop :stuck_out_tongue:

I tried googling the issue but didn’t find any answer to my problem, please help this is frustrating ^^

Have you used the Visual Studio Tools for Unity?

I’m using VS2013 so things may have changed, It’s needed to generate the project files which should provide the auto completion for Unity library. If you create a new project file you have to attach the package and generate the project files again.

Ok I repaired visual studio and now it works ^^

I switched to Visual Studio mid project and couldn’t get the autocomplete to work in VS on my existing scripts. Creating a new (empty) script in Unity and opening it from the project editor to VS fixed this issue for me, now all my scripts have autocomplete.

Might be worth a try if you’re in the same boat.