Showing posts with label visual_studio. Show all posts
Showing posts with label visual_studio. Show all posts

Tuesday, January 20, 2015

How to configure a Unity project to use VisualStudio

I started a new 2D project to try and see if I could port an old game I did in Java called EmPathMe (http://www.woodsgoods.com/gaw, Good luck getting it to run).

When I went to launch a script in VisualStudio it complained there wasn't a .sln file so I had to figure it out again. I'm leaving myself this post so I don't have to figure it out again.

You select Assets/Import Package/Custom Package...
 
Then you navigate to the location where the VisualStudio Tools for Unity were installed (http://unityvs.com/). I installed them in the default location C:\Program Files (x86)\Microsoft Visual Studio Tools for Unity\2013. The debug only works well with VisualStudioPro and I have no idea how I'm going to pay for the pro version once my  That's one reason I'm setting this up so I can get the touch code working well before my trial license expires

 
Choose all the package assets.

 
Now you will have the Visual Studio Tools menu and you can generate the project files so you don't see the error about not having a .sln file when launching the Unity editor.


Friday, November 21, 2014

Surface Pro 3 and Unity for Windows Store

Recently received a Surface Pro 3 as a gift and really love it.  Was using a 5 year old Toshiba that was limping along even with the 128GB SSD. The SSD made it viable for quite a while, but it was really getting behind. Enjoying the new Surface. First loaded Unity and Visual Studio Express 2013.  It seems like I can finally develop on an airplane even if the seat in front of me is reclined and I'm next to a 300 pounded.  The laptop was just too bulky to use when someone was sitting next to me.

So far I spent a lot of time getting Unity and Visual Studio connected together using UnityVS. Not that I don't think Mono Develop isn't good enough, I do like that, but for some reason I'm drawn to Windows Store app development and need to use VS to build Unity apps for Windows Store.

It isn't well documented, but don't try to use Visual Studio Express with UnityVS.  It won't give you an error, but will only have a message that it can't find Visual Studio.   You have to install Visual Studio Pro to work with UnityVS.  I'm now running a 90 day trial and everything is working, but will have to write quick and decide if I want to upgrade my older version of Visual Studio Pro.  I spent a lot of time uninstalling and reinstalling UnityVS to get this to work. Many messages from Visual Studio that the project type wasn't recognized.  Once I installed Visual Studio Pro it still had the same message and I reinstalled UnityVS and everything worked well.

Another thing that led me in this direcetion was trying to figure out how to debug the touch screen interface in my Unity game. This seems like it will work well.  In Unity, you have to Build the solution for the Windows Store application which will create a new folder with a Visual Studio Windows Store project.  This has the C# scripts linked in it so you can debug and change those directly and debug your Windows Store application directly.  I could have done something similar and connected my Android tablet directly to Unity and ADB debugged on hardware, but this seems like a better way and I will be using that.