Visual Studio 2013 Tools for Unity

Microsoft Free

Write and debug your Unity 3D games inside Microsoft Visual Studio.

(82) Review
Visual Studio
Download (273,077)
E-mail Twitter Digg Facebook
Add to favorites
Reviews (82)
Q and A (188)
Sign in to write a review
Sort by:

by Stefan Maton | April 21 2016

Where can we submit bug reports for the tool?

I have this problem:

Debugger detaches when using 2D arrays.

1. What happened

While debugging the code in file "BugCode", the debugger detaches in line 14 containing the code "x++;". This happens always.

When commenting out line 11 containing the if-statement (while keeping line 12), the debugger works as expected.

2. How we can reproduce it using the example you attached

- Open BugScene
- Open BugCode.cs in Visual Studio Community 2015 (with Visual Studio Tools for Unity
- Attach Visual Studio debugger to Unity
- Place breakpoint in line 9
- Start game in Unity.
- Debug step by step.

using UnityEngine;
using System.Collections;

public class BugCode : MonoBehaviour {

// Use this for initialization
void Start () {
int[,] things = new int[10, 10];
int x = 0;

if (x >= 0)
things[x, 0] = x;

Debug.Log(things[x, 0]);

Sebastien Lebreton April 22 2016
| Edit |

Hello Stefan.

You can use the support email vstusp[at]Microsoft[dot]com

I will check you repro to find and fix the bug

Is this something you are reproducing when using MonoDevelop ?

Sebastien Lebreton [MSFT]

by alexjosesilva | December 21 2015

Estava procurando há muito tempo por este plugin. Vai mim ajudar em meu desenvolvimento de jogos.

by Lordinaire | July 29 2015

Great tools !

by Stephen Hodgson | July 20 2015

Great tool.

It's saved me lots of time, and love the price.

by DG Osborne | July 18 2015

Thanks for this! Having Visual Studio for Unity development is a must.

by XenStalker | June 12 2015

by formulahendry | April 23 2015

by Protostar Dean | April 21 2015

Great Tool!
However since getting this latest update Unity seems to be crashing very frequently when I am attached.

by 金奇 | April 18 2015

very good

by Bakinovski | April 16 2015

While I am debuging I can't see exceptions in debuger.
For example in such source code I can't see object exception at line with Debug.Log
throw new Exception("test exeption");
catch (Exception exception)
UnityEngine.Debug.Log("Test exeption was thrown!");
Do you have the same issue? If it is bug do you plan to fix it?

P.S. Tool is realy grate - thanks for it.

Sebastien Lebreton April 20 2015
| Edit |


Yes, at this time, the exception object is not properly added to the debugging context so that you will not be able to inspect it using Watch window.

We will add support for that in the final release of VSTU 2.0.


by Kuato4 | April 13 2015

by QuYong | April 11 2015

very useful tools for Unity game developing, forget about the MonoDevelop

by KingRecycle | April 11 2015

New version doesn't work for 32-bit so I can't use it anymore. Please fix this.

But other than that it's better than using anything else in my opinion.

Sebastien Lebreton April 11 2015
| Edit |


We have just re-uploaded a new installer with proper x86 support.
Can you please download the file again and try to install it ?

Sebastien Lebreton [MSFT]

by CodePiao | April 07 2015

Very Cool .

Use VS 2013, coding for Game。

by AByrd | April 06 2015

A few issues with

Output is now spamming "The thread 0x<stuff> has exited with code 0" at a rate of about 2 per second.

The Error List now flickers open and closed frequently.

Sebastien Lebreton April 09 2015
| Edit |


When debugging, we've always notified what's happening in the output window, including thread creation and death.

You can configure VSTU to not send the Unity console to VS this will avoid the flicker you're seeing. You can do it from Unity, in the menu Visual Studio Tools -> Configuration and uncheck Send Console to Visual Studio.

by nu Assets | March 30 2015

Although the system has some minor bugs, it's probably one of the mightiest add-on you can get for Unity 3D. The integration is 99.9% seamless and its usability is pretty nice. If you're used to work with VS - you probably are as a professional - there's no way around it!

Well done!

by CoRuMmo | March 10 2015

Cannot come back to mono develop. I can't simply stand its interface anymore.
Long life Visual Studio tools for Unity!
Many thanks for this must-have tool.

by AdamNash_FM | March 03 2015

by Yatajga | February 20 2015

by Chad Keating | February 19 2015

1 - 20 of 82 Items   
Sign in to start a discussion

  • VSTools 2013 installed, but Unity integration failed
    2 Posts | Last post May 10, 2016
    • I installed the whole Unity+VS2013 stack the third time and I cannot make it work.
      I do it like this:
      - install german version of vs2013
      - install Update 5
      - install english language pack
      - switch to english version
      - install Unity 5.3.4f1
      - install VSTools for unity from this site
      Startup unity, switch the editor to Visual Studio 2013 (Doesn't get detected automatically, have to find the devenv.exe by hand)
      Notice, that in the Help > About Unity window, lower left corner, the indication text for the vs tools are *not* present.
      I delete the .csproj and the .v12.suo file, go into our unity project, open up VS with the Assets > Open C# Project.
      In VS2013, there is no Unity tab, no "Attach to Unity" button, instead a regular "Start" button, which leads to an error message when pressed.
      There is a "Attach to Unity Debugger" menu entry available tho.
      I would like to repair my installation, that I have the "Attach to unity and Play" button available, and the Unity Project Explorer instead of the regular Solution Explorer. Something seems to be amiss.
    • Hello,
      The issue is here: "Startup unity, switch the editor to Visual Studio 2013 (Doesn't get detected automatically, have to find the devenv.exe by hand)"
      Sometimes you have to reboot your computer so that Unity will be able to detect VS. If you select by hand a file, Unity will not use the special code path that calls VSTU to properly generate project files with our own marker.
      Without our marker, you will stay with a regular C# project without all VSTU wizards and debug engine.
      Sebastien Lebreton
  • DLL debugging and static properties
    2 Posts | Last post April 25, 2016
    • Hi,
      We have a medium-large vs solution consisting of 11 projects.
      Each project outputs a DLL and the DLL (incl. PDB) gets copied to Unity using a postbuild action. When making changes to one of the projects and the solution and/or project gets rebuilt, breakpoint debugging doesn't work anymore. One have to manually reimport the assemblies in Unity to make the debugger work again. The files copied by the build action get automatically imported by Unity, but somehow break the line between visual studio.
      When it's working then, static properties/fields get not reflected (at breakpoints) if those are defined in an other project but within the same solution. Instance variables get properly reflected.
      Is this a known problem or do I miss something here?
      Thank you for your answer.
    • Hello,
      We should automatically convert pdb to mdb (used by mono for symbols). Can you double check that the mdb file is properly updated when you copy dll+pdb in the project ?
      When symbols and source files are not in sync, VSTU can be unable to handle breakpoints.
      Any chance you can share with us something so that we can repro your issue?
      Sebastien Lebreton [MSFT]
  • vstu2.2 for vs2013 provides IntelliSense
    2 Posts | Last post March 23, 2016
    • when I install vstu2.2 successful,but it can not provides IntelliSense.why?
    • Hello,
      Can you check that you have XML documentation files in the folder [Your Project]\Library\UnityAssemblies\
      Those files are used for intellisense.
      Sebastien Lebreton [MSFT]
  • why i can not install vstu?
    2 Posts | Last post February 18, 2016
    • acturely , any of vstu(vstu2010.msi, vstu2013.msi, vstu2015.msi) i can not install
      all of them when click 'Install', then a window flash, then go to finish. and the message on 'finish' window says: '... ended because of an error'
      i use log to install, and maybe below is the issue, but i don't know how to fix it:
      Action start 12:54:59: SetUnityProperties.
      MSI (s) (B4:50) [12:54:59:392]: Invoking remote custom action. DLL: C:\Windows\Installer\MSI6D3.tmp, Entrypoint: SetUnityProperties
      MSI (s) (B4:7C) [12:54:59:392]: Generating random cookie.
      MSI (s) (B4:7C) [12:54:59:423]: Created Custom Action Server with PID 7028 (0x1B74).
      MSI (s) (B4:4C) [12:54:59:450]: Running as a service.
      MSI (s) (B4:4C) [12:54:59:451]: Hello, I'm your 32bit Impersonated custom action server.
      SFXCA: Failed to create new CA process via RUNDLL32. Error code: 2
      CustomAction SetUnityProperties returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
      Action ended 12:54:59: SetUnityProperties. Return value 3.
    • Hello,
      Can you send us an email here with your complete log:
      Sebastien Lebreton [MSFT]
  • Is there a way to auto modify the solution VSTU generates?
    2 Posts | Last post January 21, 2016
    • I searched on the internet and get this very simple class code put in my editor folder, hoping the unity to call my method to allow me to modify the generated C# solution.
      using UnityEngine;
      using UnityEditor;
      public class NewBehaviourScript : AssetPostprocessor
          static void OnGeneratedCSProjectFiles()
      but it seems nothing happens when I click "Open C# project" from the menu item.
      BTW, I am using the Unity 5.2.2, do you know what I do wrong here? 
    • Hello,
      The best way to interact with VSTU file generator, is to use our custom entry points:
      Also be sure that VSTU is enabled (VS must be chosen as the external editor)
      I made some examples here:
      Sebastien Lebreton [MSFT]
  • Can't install
    2 Posts | Last post January 08, 2016
    • During installation process, installer get stucked at "Configuring Visual Studio 2013 Templates" phase.
      Unity v5.3.1f1
    • Hello
      This configuration step can be very long, but if it's really stuck, you should try to:
      - Restart
      - Go to Programs and Features > Visual Studio 2013 > Change > Repair
      - Retry to install VSTU
      Sebastien Lebreton [MSFT]
  • Feature Request
    4 Posts | Last post November 29, 2015
    • VSTU has been an absolutely awesome tool for a long time now, and I'm looking to integrate it more deeply into my studios development process. I've come across a few small hiccups that I'd like to share.
      We have reusable code that gets used in all of our various projects. These tools are versioned separately and live in their own VS solution. This solution is built into managed DLLs with .mdbs.
      What I'm trying to accomplish is an extremely streamlined development experience where the tools source is able to be viewed, modified, built, and debugged all from the normal Unity VS solution, but there are a few "quality of life" concerns.
      1) Added project dependencies are removed.
      If I add the tools projects to the Unity solution, then set the Unity projects to depend on them, the dependencies will get blown up when the solution changes. If it weren't for this, it would be possible to have a single step compile in VS where it would compile both the Unity projects and the tools projects and deploy (post build step) the modified tools to the Assets folder. This would be *awesome* for workflow.
      2) "Go To Definition" on a tools symbol navigates to the Object Browser for the DLL, instead going to the tools source file.
      This is likely the most difficult to address, but would do wonders for workflow. The cause is that the Unity projects have references to the compiled DLLs in the Assets folder, not to the tools projects. Strictly speaking, this is "correct" behavior, but it introduces a disconnect when navigating from the Unity project code into the tools project code. One solution here is to allow us to set specific references to be ignored and not added to the VS solution. If I could do that and issue 1 above was addressed I'd be able to 'replace' the tools DLL reference with a reference to the tools project and "Go To Definition" would go straight to the tools source.
    • 3) Double clicking a log statement in the Unity Console won't take you to source files in the tools project.
      It will only take you to the highest point in the stack that's in the Unity projects, despite the fact that the stack contains the full path and line number to the tools source because of the .mdbs. In a few cases this is desired (we have a wrapper around Debug.Log that we want to ignore so it takes us to the line where the information was actually logged), but most of the time it is not. It would be great if the default behavior took you to the source line, even if it's in one of the added tools projects. It would also be great if this were optional (e.g. would ignore methods in the stack decorated with [DebuggerHidden] or similar).
      4) Solution folders are erased when the Unity VS solution is updated.
      The tools solution has multiple projects. I'd like to be able to collapse everything related to the tools in the VS Solution Explorer. Right clicking the solution allows me to add a folder solution folder that I can parent the tools projects under. But when Unity changes the solution file (e.g. when a reference is added or removed in one of the projects), these folders will disappear and projects end up at the root level in the Solution Explorer again. 
      Issues 1 and 2 are the big ones here. With those out of the way, VSTU will provide a fanstastic workflow where external DLL projects are treated almost completely identically to source code in the Assets folder, and that would be simply amazing.
      As always, thanks for the great piece of software.
    • Hello,
      Thanks for your suggestions and your time, this is really appreciated. Yes we are aware of that and we want to improve the whole workflow.
      Currently I think you can achieve #1 and #2 by using our custom API.
      I made a demo project on my github page:
      Can you have a look and see if it can help you ?
      Sebastien Lebreton [MSFT]
    • I'll check it out and provide feedback this week. Thanks for the heads up.
      Is there a way to enable email notifications for discussions here?
  • File names converted to lower case
    4 Posts | Last post November 25, 2015
    • Hi,
      I'm using VS2013 via Parallels, Unity 5.0.1p1 and Tools version 1.9.9. Sometimes, for reasons I can't figure out, the file names get renamed as lowercase whenI save - e.g. MyClass.cs to myclass.cs. This of course causes issue in Unity. I can force the file to save as camel case by simply saving the file again. Oddly, the file name in VS doesn't appear to change. I can't be sure.
      Looks like there have been problems with Unity doing this in the past, but nothing I could find recently. Any thoughts?
    • Hello,
      Do you hit this issue every-time or randomly ? If you are able to find a way to easily reproduce it would be great.
      Sebastien Lebreton [MSFT]
    • Sorry for the late response. I haven't been able to identify repro steps for this, but it does seem to be associated with Unity crashing. It is also happening in VS2015 preview, but with far less frequency - in fact only once in the last month. 
      I'll keep an eye out for it happening again and try to figure out if there are clear steps to it, but so far it looks random.
    • I'm getting file renaming messages few times a day, usually on the files that I modify. Something (Unity, VS2015, VSTU) is renaming from camel case to lower case and than back to camel case.
      Is there some way to turn this off?
      I'm running Unity on OSX, and have noticed this issue for the first time when I upgraded from Unity 5.1.3 to 5.2.2, and I'm getting few times every day since then.
      See example of error, renaming both ways within a minute.
      Renamed .meta file 'Assets/Game/Src/Game/Params/Combat/MegaShipParams.cs.meta' to 'megashipparams.cs.meta' because the .meta file had an inconsistent case.
      Renamed .meta file 'Assets/Game/Src/Game/Params/Combat/megashipparams.cs.meta' to 'MegaShipParams.cs.meta' because the .meta file had an inconsistent case.
      I'm using VS2015 inside Parallels to edit files, it might be VS that's renaming them, but I've never had this issue before till I upgraded unity. The class name inside the file is camel case as well.
      I've just realised I'm using as well, I'll try to disable that.
  • VS2013 "Attach to Unity" button does nothing
    6 Posts | Last post November 20, 2015
    • Hello,
      I am running Unity 5.2.2f1 with Visual Studio 2013. I have Visual Studio 2013 tools for Unity installed. When I open a script from Unity, it opens VS2013 properly as it should. I also imported the packages Visual Studio tools for Unity. I am on Windows 10.
      My Problem: when I click on "Attach to Unity' in VS2013, nothing happens. The button becomes unavailable for 3 seconds as if VS was trying to connect but then nothing. No error message but my breakpoint won't hit.
      Any idea what could be going wrong?
    • I have exactly the same setting than when I was running the extension on Windows 7. Could it possibly be a privilege issue with Windows 10 that prevents VS from connecting to Unity?
    • Did you check your firewall settings ? Seems like there is a timeout trying to connect to the debuggee. 
      Sebastien Lebreton [MSFT]
    • What kind of parameter am I looking for?
    • I deactivated Windows's firewall and my own (bitdefender) but it didn't change anything :(. When I click attach to unity, I just have a message saying that the build is successful in the output window, but nothing else.
    • Is there any debug tools or information that could at least help me figure out at what  point the "Attach to Unity" is failing?
  • unity tools 2013 wont install
    3 Posts | Last post November 05, 2015
    • I have downloaded and installed this package and windows sees it installed because when i run the installer again it gives me the option to repair.  However in visual studio I don't have the Debug > Attach to unity option.  Also when I open extensions and updates unity tools is not listed.  
    • I amusing Visual Studio Ultimate 2013 with update 5.  Unity 4.9.x, on windows 10
    • On rare cases, the extension is not properly registered. Can you try to repair VS and/or VSTU ?
      You can also try to manually run devenv /setup to register all extensions.
      Sebastien Lebreton [MSFT]
1 - 10 of 188 Items