[Tools] MonoDevelop vs Visual Studios for Unity

edited in Questions and Answers
Hi guys

got a question to ask regarding coding for Unity games.
ok now 1st of all i am very new to game dev so im gonna be asking a lot of questions :P

but the 1st one if, which programming software should i use when working with Unity?
i have noticed that Unity has a embedded type thing with Mono-develop, now i have use it a bit during the tutorials that i have been doing and its quite nice, now the reason i am asking is i was talking with a few programmers at work (not game programmers) and they told me that Visual Studios would be a much better option for me to use.

now is this true or would it just be the same no matter which i use? or would either one of them be better in any way and so on?

thanks :)

Comments

  • edited
    Disclaimer: I'm not a serious programmer, I only care about getting things done fast and simply. I have used both programs, but for the last year have stuck with Visual Studio.

    My understanding is this:

    Monodevelop has the advantage that if you want to step through your code while testing your game you can. Some programmers find this VERY powerful. I don't really understand it.

    Visual Studio has the advantage that its auto-completion, error highlighting and formatting are better (or certainly was a year ago). This I like as it helps me write code faster without me having to interrupt my workflow and go to Google to find things out.

    Monodevelop is being actively developed by Unity. So may accrue some advantages over time.

    Visual Studio is the choice of most programmers and runs slightly more lightweight than Monodevelop (which I like on my underwhelming laptop).

    There may be other differences, but inferior auto-completion was a deal breaker for me with Monodevelop. Though I did use Monodevelop on some projects just fine (when I was working on Mac).
  • edited
    As always, there is a trade-off between the two.

    Overall, I like Visual Studio way better than MonoDevelop. The principle reason is simply that it crashes less. (Some people do not have this problem, I also have a few unique MonoDevelop rendering and freezing issues no one else seem to have).

    MonoDevelop does integrate better than VS Express (you cannot have C# files open properly in VS Express by double clicking on them in Unity). If you have access to VS Professional, that solves the problem; however it is quite expensive. (Which is a shame; it really is wonderful. I guess that is why it is expensive).

    The other thing is that you can run the debugger on a Unity game from MonoDevelop, which you cannot do with VS. Apparently there is a plugin that makes this possible for VS too, but it costs $100. (I have not tried it yet).

    When using free tools, I use both VS and MonoDevelop. I use VS when I write large blocks of support code that I can test without running Unity. For the rest I use Mono.

    (I recently got an upgrade, and said goodbye to MonoDevelop without tears).

    My suggestion would be to use both and see what each has to offer. And don't worry too much about which is best; over time you will learn to leverage whichever tool you are using. (So if using both is too much for now, choose one for now, and check out the other later when you are comfortable. Fortunately, IDE choice is not marriage for life :P)
    Thanked by 1mattbenic
  • edited
    thanks guys for your replies they did help :)

    the plugin i think you talking about is UnityVS , its quite interesting and i have bee really tempted to try it out :) [edit - im now doing just that]

    and from what i have seen while using a trial of VS its really nice the face that i can change the theme to a dark theme also helps my eyes "i know that's a small thing but it helps"

    and the coding style is quite nice and fast, jusat struggling to get it to open .js files in it.
  • edited
    I think Monodevelop is better at handling .js files. I might be doing something wrong in Visual Studio, but .js files are always just plain text for me with no auto-completion (because my projects are largely in C#).

    So I end up converting the javascript to C# which is a pain. I think Monodevelop won't give you this problem.
  • im also getting that problem with the plan text, so im installing UnityVS now to see if that helps.
  • I prefer VS. The latest version allowing me to search through the project tree easily is awesome :)

    I've always treated step-debugging and writing actual code as different operations, so I switch to MD for that if I need it.
    Thanked by 2EvanGreenwood Fengol
  • Visual Studio plus Resharper ( a visual studio plug-in) is an insanely powerful combination. The code intelligence that resharper provides is simply phenomenal.

    BUT (BIG B-U-T, SO BIG I'M GOING TO SAY IT AGAIN: BUT!) if you're just starting out none of this really matters. Monodevelop is perfectly capable, I've used it for years. Ignore the passionate arguments of fanboys who insist "x" is going to be so much better than "y" that you might as well not even bother with "y". All you really need right now is a place to type code. I know I know, this whole game dev thing is very intimidating and you want to make sure you get it right from the start. Well in this case the right thing to do is focus on starting and not the marginal differences in your tools. Once you've typed in a lot of code then this question starts to become a lot more relevant ;).
  • edited
    I personally use Monodevelop for Unity dev.

    VS is the better IDE (I'm a fan), though MD is serviceable enough. But I'm also one of the programmers BlackShips mentioned who finds step debugging, callstack tracing etc to be an extremely powerful tool in a programmer's toolbox, especially when working on complex systems. To the point where the loss of that functionality is a deal-breaker for me.

    Some devs get around that by switching between the two as the need arises. If that works for you, cool. Personally I find it aggravating to work like that. Rule of thumb, choose whatever best suits your workflow as a dev.

    UnityVS may be the best solution, when I've got some free time and cash I'll give it a whirl. In fact, if anyone's using it, report back, I'd be interested in hearing about your experiences.
    Thanked by 1AngryMoose
  • We predominately use MD. Not as a choice more as a it was the default and now we stick to it.

    That having been said with the Windows 8 work we have been doing VS was thrust upon us not in the bad way more in the finally a good reason to use it way.

    I am not sold that either suits us better, my gut feel is that VS is a more complete solution but MD is a little closer to the heart of the Mono CLR. That purely bias not fact.

    We don't use line by line debugging I am not a fan. I prefer logs that persist after the debugging session so that my bug tracking leaves me with an asset for future bug tracking.

    Personally I would like tighter coupling either way. Does anyone know if VS can handle refactoring class or method names so that Unity behavior allocation will automatically update. Refactoring is a huge asset to someone with pour spelling :) i.e. me.
  • Oooh! I'm going to look into Resharper. Thanks for the tip @Funtastic!
  • @tbulford VS is much better at handling refactorings than MD; I rename stuff and split off methods very wildly all the time. The only caveat is naming files, which you should not do automatically in VS (VS also does not offer to do this if the name spaces don't match the folder structure). Of course, renaming public variables require some care, since you will lose references (but not always, I think... it may be imagination or bad memory).
    Thanked by 1tbulford
  • Been spoilt by Eclipse for too many years now. Refactoring is a dream there.
    Thanked by 1hermantulleken
  • edited
    @tbulford one word: R-E-S-H-A-R-P-E-R! :D

    It's built by jetbrains, so it's up there with the likes of Intelli-j. The things it knows about my code is just ridiculous sometimes. And in my not humble opinion creams the refactoring smarts available in Eclipse. ;) Only slight negative is that it's a little bit enthusiastic with it's best practice suggestions sometimes. But that I can live with.

    Edit: not sure what the implications of file renaming are with unity. That might still be a bit fiddly. Everything else works great though.
    Thanked by 1tbulford
  • So for what it's worth, I use the UnityVS plugin a couple of people have brought up, and it works exactly as advertised. I used MonoDev very infrequently before (only for deubgging, like @dislekcia), but with UnityVS I no longer need to make the switch at all. Everything is seamlessly and perfectly integrated into Visual Studio. It behaves very well with Intellisense as well, as the most recent versions of UnityVS add Intellisense tips for all internal documented Unity methods, which means less having to dig through Unity's API docs.

    Basically, that's the best option I've encountered, and I would recommend to any programmers. For hobbyists, of course, Monodevelop is perfectly serviceable, if you don't want to (or otherwise cannot) splash out on VS Pro and UnityVS plugins.
    Thanked by 1hermantulleken
  • Ah, awesome, thanks for the feedback.
  • You guys are seriously selling me on UnityVS.
  • Ditto... downloaded the trial; will see how it goes.
  • @TheFuntastic will take a look at it the JetBrains guys build aw some tools. Bit pricy sometimes but awesome. Its just best to rename any MonoBehaviour class in unity then go rename the actual class in MD. Fortunately that's not something that has to be done too often.
  • I must also check out UnityVS. I can't recommend Resharper because while it's a powerful tool with lots of features it slows down VS because there are now 2 passes on the code files; one for VS and another for Resharper. VS doesn't open it's parsing functionality for extensions. But I'm busy using VS2013RC which has nearlly all the Resharper functions including the function references which is a pretty handy tool for refactoring.
  • Right, so this is probably the silliest reason...but I choose to work with VS because I like the default color formatting for the code.
  • I like VS because it's auto-indent removes annoying egyptian braces. (CTRL K - CTRL D)

    Seriously though, I don't mind monodevelop but its code completion and confusion between different method signatures is humourously bad at times (it's ok monodevelop, arrays confuse us all at times.......). If that UnityVS does what it advertises then there's no reason to ever start up monodevelop.

    I used Resharper extensively in a previous life where we had strict code conventions and it's amazing for that and several other reasons. Highly recommended if you can afford it and are a power-user.
  • My favourite thing about Monodev is how it generates hilarious Engrish automatic XML comments for your methods.

    When you look at text all day, it's the small things that amuse you...
  • @Rigormortis you know in MD you can set the coloring to VS-style?
  • Yes, but then I'd have to do something extra :P
  • Speaking of code colours... The default colouring in GMS. Aaaargh! What am I, leet?
  • @dislekcia I don't mind the GMS colours that much. Though it is rather red heavy, given the chance I use Sublime for my code editing, (GMS doesn't like scripts over a certain length) but that involves a lot of copy-pasta since it takes a minute after I save the script for GMS to realize I have changed something.

    Though TBH my current view of GMS is that I can't wait to move to Unity (you can't do a recursive call in GMS more than 32 times . . .)
  • edited
    @raithza said:
    I like VS because it's auto-indent removes annoying egyptian braces.
    Lol, first time I've heard the expression Egyptian Brackets. A pet peeve of mine!

    http://www.codinghorror.com/blog/2012/07/new-programming-jargon.html has a nice list of these, including:

    Yoda Conditions
    (5 == count)


    and Pokemon Exception Handling:
    try {
    }
    catch (Exception ex) {
       // Gotcha!
    }
  • Haha Yoda and Pokemon :P

    I am a total noob, but my feelings on Mono so far. It could do more. Its damn annoying that the autocomplete only comes up after a period. I'll try out VS some time this week and see which I like more :)
  • Oddly enough, I actively use egyptian braces when I'm working in GML, but I hate them in C#. I love the VS auto-indent nuking them :)

    It's probably because every GML script window is ridiculously tiny, making me want to conserve screen space so that the whole method/function/blah can be seen at the same time. While VS has more space so nicely arranged code feels better.

    I know that GML's crampedness made @Squid have some seriously strange coding habits when he started out ;)
  • Its damn annoying that the autocomplete only comes up after a period.
    I think you can press Control-Space in mono to force autocomplete
    Thanked by 1RickyGC
  • Pretty sure you can change the autocomplete delay to 0 in settings. I wouldn't have been able to use it otherwise...
  • Who even uses autocomplete with a delay... Most useless IDE setting ever.
  • I looooooooove me some egyptian braces. I am however quite flexible on that when working in teams. :) I just like code that saves vertical space.
  • edited
    I tried UnityVS for a month using the free trial and it worked very well (haven't got round to buying it yet). I've been developing in Visual Studio for so long that using MonoDevelop significantly hinders my productivity (despite many of the differences seeming subtle or trivial, they add up). I wish Unity would just acquire UnityVS and make it a standard part of the package.
  • edited
    I am however quite flexible on that when working in teams
    @Rigormortis, yeah I think you have to be if you want to maintain your sanity. I have a natural tendency to be repelled by many coding conventions I see, but over time I've had to tone down my obsessive perfectionism and accept that there is nothing special about the coding conventions I choose to adopt and have become accustomed to. No matter how ugly the code looks to you, if you work long enough using that convention you'll become used to it and probably start to like it. Even my own older code looks dreadful to me, though at the time I thought it was neat and visually pleasing.
  • Monodevelop has the advantage that if you want to step through your code while testing your game you can. Some programmers find this VERY powerful. I don't really understand it.
    @BlackShipsFilltheSky, you need to learn how to use the debugger to step through the code, it will change your life for the better!!! I remember back in my university days we weren't taught how to use the debugger to step through code etc, I only learnt it on the job and didn't initially perceive the value in it. Now I cannot fathom how I would get by without it.
  • I'm also a major fan of VS, and use it wherever possible (bad actually, because I end up using real debugging less and depending on inferior substitutes like text debugging). There's a good chance I'll be using UnityVS soon though.

    One thing that hasn't been mentioned yet is that MonoDev is cross platform, so while it's nowhere near as good as VS, it does have the advantage of being a relatively consistent environment to use when you're switching between Windows and Mac.
    @raithza said:
    I like VS because it's auto-indent removes annoying egyptian braces.
    Yuck!
    Nitrogen said:

    Yoda Conditions
    (5 == count)

    Love my yoda conditionals, do I :)
    They're an old habit from C/C++ coding in simpler tools where you could accidentally assign when you meant to compare, and spend the next couple of hours trying to figure out why your code is doing stupid things.
  • As a code noob, should I be ditching MonoDevelop for something else? I'm finding the indenting super confusing, and having to manual all my indents is kinda doubly confusing me...
  • indenting super confusing, and having to manual all my indents
    0_0

    I use Monodevelop. I just got used to it, and didn't have VS Express installed at the time -- and when I finally did, the keyboard shortcuts made no sense to me. (MonoDevelop's comment/uncomment is just Ctrl+Alt+C, whereas VS's default is... something retarded.)
  • Tuism said:
    As a code noob, should I be ditching MonoDevelop for something else? I'm finding the indenting super confusing, and having to manual all my indents is kinda doubly confusing me...
    I'd suggest the opposite. As much as I prefer VS, starting out you should waste as little time as possible trying to find the perfect set of tools. Mondev's excellent integration with Unity means it's a good choice unless you have a solid reason to switch. The style may be annoying, but you'll probably get used to it pretty quickly.

    Yes, even the stupid Java-style Egyptian braces.

    P.S. Yes, I know you can change those in settings, but I've found Mono's pretty inconsistent about when it chooses to apply custom styling, and when to ignore it.
  • OK cool thanks guys :) I'll stick with it. And I found that you can auto Indent the whole thing. Guess I'll use that and learn the crap out of it :)
  • Starting out you should waste as little time as possible trying to find the perfect set of tools.
    Noooo! Ok wait, maybe (depends on whether the guy is totally new to developing or has at least SOME experience -- a year or two). But good tools benefit you enormously.

    Then again, my primary reason for liking Visual Studio is experience with it and becoming accustomed to it, so my opinion is probably incredibly biased :P
  • @tuism don't worry about tools dude. Switching ides down the line is at worst simply annoying for a period of time and then stops being annoying when productivity resumes.

    Learning how to code in any IDE is way more important. User of both monodevelop and Vs for some time now...
  • Noooo! Ok wait, maybe (depends on whether the guy is totally new to developing or has at least SOME experience -- a year or two). But good tools benefit you enormousl
    Sure, if the default (monodev) was outright bad, I'd agree. But when you don't even know what you prefer yet, and the choice isn't black and white (one is an absolutely clearly better choice, whith no ifs, buts or maybes) you may as well stick to the default and just get developing.
  • I tried the UnityVS trial with Visual Studio 2010 Pro and was very disappointed. I found the plug-in highly temperamental. Often all the locals would just disappear between window changes and wouldn't return until I performed another step-over/into/out (including examining variables in the text-editor) and it would outright crash occasionally. The Watch and Immediate windows didn't work at all. I just stick with MonoDevelop now.
  • During a particularly ugly set of crashes just before DD's launch I tried to debug using both UnityVS and MonoDevelop and couldn't get ANYTHING working at all. Switching between different project files simply wasn't something that I was able to manage in the middle of an enormous and complex project.

    I thought that using "proper" debug tools would cut down on the time it was going to take me to solve the issue I was having, but in the end it just added hours of frustration for no progress. I'm planning to go back and explore both UnityVS and MonoDevelop's debugging features with a brand new, clean project file, but only after we've finished supporting DD.
  • edited
    My experience with UnityVS has been good. It does crash, but for some reason MonoDevelop is extremely unstable on my machine, so I crash less often now. The one thing I dislike about it is that it seems to mess up projects when you do not want to use it (this is particularly irritating this month where we are dealing with 30+ projects...grrrr).
  • In related news:
    Microsoft acquires SyntaxTree, creator of UnityVS plugin for Visual Studio

    Of particular interest:
    With this acquisition, we have the opportunity to integrate this support for Unity even more deeply into Visual Studio, and to continue to push forward Visual Studio's support for game developers. Microsoft will also make the existing UnityVS plugin available for free on our download site shortly.
  • Late to this train, but the above I think is good news.

    I am currently using Monodevelop solely because I can't use VS 2013 Update 2 for some reason. Monodevelop keeps auto-indenting and rearranging my code and it really bugs me, I spend more time fixing lining up of my code than writing actual code in monodevelop.

    As a note, my controls are set to Ctrl+E,D to format document and Ctrl+E,C to comment or uncomment in Visual Studio. I haven't yet formatted a document automatically in VS and not liked the changes it has done (fixing brace alignment and all that for me if I am lazy).

    Admittedly I would like proper error messages in IDE in either (like syntax errors etc) - I remember there being a distinct lack of this in VS when I was using that and I know monodevelop is pretty silent on the fact that it shows everything is fine when in fact you have some large syntactical error in code (mostly in shaders admittedly).
  • Yeah, I had to do some heavy solutions policy editing in Monodevelop to have its syntax correction stuff not totally suck. Unfortunately this seems to change per project, and reimporting an exported policy file doesn't always seem to work. >_< Might be, in part, that you seem to have to change it in, like, three different places...
Sign In or Register to comment.