Hi folks - I am looking at the terminal hacker program, all appears to be going well until I try to open the Hacker.cs file, then visual studio creates the project, but the source file appears in mono develop not visual studio - any thoughts ? SOLVED BY Update to VS = problem re-occurs
more info - works perfectly well with a file linked to a simple object like a cube, but not to the more complex prefab
If anyone else is having a problem like this, you can check your Unity settings:
Edit: Preferences… External Tools. “External Script Editor” should be set to Visual Studio.
You may find that even with Visual Studio selected MonoDevelop still launches and tries to open the script, but fails with opening the project. Often Visual Studio can be a little slower to launch, MonoDevelop seems to jump the queue.
any solution to this - the problem I had yesterday has just resurfaced
I personally haven’t looked very far into it as it happens infreauently and seems to only occur when Visual Studio is slow to open. My laptop is normally left on for a week+ with Visual Studio open for normally the same amount of time.
If I were to try to resolve it, I would probably start by removing MonoDevelop, this would limit the likelihood of it being opened as well. I suspect they both end up in a nun fight over which will open it and subsequently block each other.
If it still occurs after this I would be checking file associations next, ensuring not just the .cs file exentsions but also the project and solution extensions were all mapped to Visual Studio.
If it still occurs after this, I would look through the registry for any references of “mono”.
Its at this point where, for me personally, it seems a lot more effort than return on investment due to the infrequency. I tend to just close MonoDevelop and Visual Studio and then double click from Unity again and its all fine.
Hope this helps.
Thanks Rob appreciate the help, I use VS for a range of different purposes,
and my installation is a bit of a monster, but I am working on quite a
beefy machine at the moment, In desperation I have now moved my unity
projects directory off one drive to see if that is causing a problem with
all the file access that this involved in case this was the source of the
problem.
You’re welcome.
Another test could be to perhaps disable/remove any additional extensions/tools with Visual Studio to help speed up the loading times, I have personally noticed a bit of a slow down in more recent versions but obviously the product has grown in features.