{"id":3461,"date":"2015-04-06T10:00:00","date_gmt":"2015-04-06T10:00:00","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/visualstudio\/2015\/04\/06\/visual-studio-tools-for-unity-2-0-preview-2\/"},"modified":"2022-05-18T06:26:24","modified_gmt":"2022-05-18T13:26:24","slug":"visual-studio-tools-for-unity-2-0-preview-2","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/visualstudio\/visual-studio-tools-for-unity-2-0-preview-2\/","title":{"rendered":"Visual Studio Tools for Unity 2.0 Preview 2"},"content":{"rendered":"<p>Today we release Visual Studio Tools for Unity 2.0 Preview 2. VSTU is Microsoft&rsquo;s free Visual Studio add-on that enables a rich programming and debugging experience for working with the <a href=\"http:\/\/unity3d.com\/\">Unity gaming tools and platform<\/a>.<\/p>\n<p>The main feature of Visual Studio Tools for Unity 2.0 Preview 2 is the official support for <a href=\"http:\/\/unity3d.com\/5\">Unity 5<\/a>, the new major version of Unity that was released last month. VSTU is available for download on the Visual Studio Gallery at the following links:<\/p>\n<ul>\n<li><a href=\"https:\/\/visualstudiogallery.msdn.microsoft.com\/8d26236e-4a64-4d64-8486-7df95156aba9\"><strong>Visual Studio 2015 Preview Tools for Unity<\/strong><\/a><strong><\/strong><\/li>\n<li><a href=\"http:\/\/visualstudiogallery.msdn.microsoft.com\/20b80b8c-659b-45ef-96c1-437828fe7cf2\"><strong>Visual Studio 2013 Tools for Unity<\/strong><\/a><\/li>\n<li><a href=\"http:\/\/visualstudiogallery.msdn.microsoft.com\/7ab11d2a-f413-4ed6-b3de-ff1d05157714\"><strong>Visual Studio 2012 Tools for Unity<\/strong><\/a><strong><\/strong><\/li>\n<li><a href=\"http:\/\/visualstudiogallery.msdn.microsoft.com\/6e536faa-ce73-494a-a746-6a14753015f1\"><strong>Visual Studio 2010 Tools for Unity<\/strong><\/a><\/li>\n<\/ul>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/5123.VSTU_.Unity5_09B4FA0A.jpg\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"VSTU.Unity5\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/5123.VSTU_.Unity5_09B4FA0A.jpg\" alt=\"VSTU.Unity5\" width=\"503\" height=\"275\" border=\"0\" \/><\/a><\/p>\n<p>The support for Unity 5 aside, we continued to focus on bringing more features from the Visual Studio debugger to VSTU. The highlights of VSTU 2.0 Preview 2 include:<\/p>\n<p><strong>Option panel for VSTU:<\/strong> We&rsquo;re always working on bringing new features to VSTU. Using our option panel you can enable or disable them depending on your use cases.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/6683.settings6_3BAC9A94.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"VSTU Settings in Tools Options\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/6683.settings6_3BAC9A94.png\" alt=\"VSTU Settings in Tools Options\" width=\"504\" height=\"321\" border=\"0\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p><strong>Experimental support for breaking on exceptions:<\/strong> The ability to break the debugger when an exception happens in your Unity code is a common <a href=\"https:\/\/visualstudio.uservoice.com\/forums\/121579-visual-studio\/suggestions\/6429125-automatically-break-on-nullreferenceexception-and\">feature request<\/a>. You&rsquo;ll currently need to enable this experimental feature in our option panel, then you&rsquo;ll be able to use the new <a href=\"https:\/\/devblogs.microsoft.com\/devops\/the-new-exception-settings-window-in-visual-studio-2015\/\">Exception Settings window<\/a> to configure which exception you want to break on.<strong><\/strong><\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/3377.VSTU2Preview23ExceptionSettingsWindow_776C3347.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"Exception Settings Window\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/3377.VSTU2Preview23ExceptionSettingsWindow_776C3347.png\" alt=\"Exception Settings Window\" width=\"504\" height=\"289\" border=\"0\" \/><\/a><\/p>\n<p><strong>Function Breakpoints<\/strong><strong>:<\/strong> VSTU now supports creating <a href=\"https:\/\/devblogs.microsoft.com\/devops\/function-breakpoints\/\">function breakpoints<\/a>. A good use case for those are when you want to put a breakpoint in every MonoBehaviour message in your game code, without having to create each breakpoint manually.<strong><\/strong><\/p>\n<p><strong><\/strong><strong><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/4848.VSTU2Preview24FunctionBreakpoints_0948C715.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"Function Breakpoints\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/4848.VSTU2Preview24FunctionBreakpoints_0948C715.png\" alt=\"Function Breakpoints\" width=\"520\" height=\"503\" border=\"0\" \/><\/a><\/strong><\/p>\n<p><strong>Hit Count<\/strong><strong>:<\/strong> <a href=\"https:\/\/devblogs.microsoft.com\/devops\/hit-count-breakpoints\/\">hit count breakpoints<\/a> are a form of conditional breakpoints, where the debugger breaks depending on how many times the breakpoint has been hit while the code is running. This is particularly useful when debugging loops.<strong><\/strong><\/p>\n<p><strong><\/strong><strong><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/2705.VSTU2Preview25HitCount_2C0C8F83.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"Hit Count\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/2705.VSTU2Preview25HitCount_2C0C8F83.png\" alt=\"Hit Count\" width=\"504\" height=\"169\" border=\"0\" \/><\/a><\/strong><\/p>\n<p><strong>Object IDs:<\/strong> If you don&rsquo;t know about this little gem in the Visual Studio debugger, I invite you to read about it in this <a href=\"http:\/\/blogs.msdn.com\/b\/zainnab\/archive\/2010\/03\/04\/make-objectid-vstipdebug0015.aspx\">blog post on Make Object ID<\/a>. Basically, object IDs allow you to get a reference to an object even if it&rsquo;s not in scope.<strong><\/strong><\/p>\n<p>&nbsp;<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/3365.VSTU2Preview26MakeObjectID_0BF182C6.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"Make Object ID\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/3365.VSTU2Preview26MakeObjectID_0BF182C6.png\" alt=\"Make Object ID\" width=\"504\" height=\"314\" border=\"0\" \/><\/a><\/p>\n<p><strong><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/1222.VSTU2Preview27ObjectID_56E4F395.png\"><img decoding=\"async\" style=\"float: none;margin-left: auto;margin-right: auto;border-width: 0px\" title=\"Object ID\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/1222.VSTU2Preview27ObjectID_56E4F395.png\" alt=\"Object ID\" width=\"504\" height=\"331\" border=\"0\" \/><\/a><\/strong><\/p>\n<p>&nbsp;<\/p>\n<p>Our <a href=\"https:\/\/msdn.microsoft.com\/en-us\/library\/dn940028%28v=vs.140%29.aspx\">changelog<\/a> contains many more features and bug fixes. If you have any suggestion for VSTU, please post them on <a href=\"https:\/\/aka.ms\/uvunity\">UserVoice<\/a>, and if you encounter any issue please report it through the <a href=\"http:\/\/connect.microsoft.com\/visualstudio\">Visual Studio Connect site<\/a>.<\/p>\n<table style=\"width: 677px\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\">\n<tbody>\n<tr>\n<td valign=\"top\" width=\"161\"><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/4721.image_thumb_23AB1907.png\"><img decoding=\"async\" style=\"border-width: 0px\" title=\"image\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2015\/04\/4721.image_thumb_23AB1907.png\" alt=\"image\" width=\"144\" height=\"186\" border=\"0\" \/><\/a><\/td>\n<td valign=\"top\" width=\"514\"><strong>Jb Evain,<\/strong> Senior Software Engineer, Visual Studio Platform Team <br \/>(<a href=\"https:\/\/twitter.com\/jbevain\">@jbevain<\/a>)<\/p>\n<p>Jb runs the Visual Studio Tools for Unity experience for the Visual Studio Platform team. He recently joined Microsoft as part of the acquisition of SyntaxTree, a company he founded and where he led the development of UnityVS. He has a passion for developer tools and programming languages, and has been working in developer technologies for over a last decade.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n","protected":false},"excerpt":{"rendered":"<p>Today we release Visual Studio Tools for Unity 2.0 Preview 2. VSTU is Microsoft&rsquo;s free Visual Studio add-on that enables a rich programming and debugging experience for working with the Unity gaming tools and platform. The main feature of Visual Studio Tools for Unity 2.0 Preview 2 is the official support for Unity 5, the [&hellip;]<\/p>\n","protected":false},"author":13,"featured_media":255385,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[472,155],"tags":[9,179,182,12],"class_list":["post-3461","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-gaming","category-visual-studio","tag-debug","tag-game-development","tag-unity","tag-visual-studio"],"acf":[],"blog_post_summary":"<p>Today we release Visual Studio Tools for Unity 2.0 Preview 2. VSTU is Microsoft&rsquo;s free Visual Studio add-on that enables a rich programming and debugging experience for working with the Unity gaming tools and platform. The main feature of Visual Studio Tools for Unity 2.0 Preview 2 is the official support for Unity 5, the [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts\/3461","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/comments?post=3461"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts\/3461\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/media\/255385"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/media?parent=3461"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/categories?post=3461"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/tags?post=3461"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}