Unity & MonoDevelop 4 Woes
Unity usually always brings it to the table with their updates but sometimes they miss a few things. The MonoDevelop 4 is shiny but has one serious problem with the basics, at least on OSX. This is code folding! At first, code folding looks great. I do like the ability to fold “if” statements, but after I update something, all hell breaks loose and I can’t fold anything anymore. My workflow relies on folding to help me navigate code (as I think it is so with a lot of other devs). So here are some steps to get back to the old version of Mono. I am on OSX Mavericks, on a mac book pro BTW. I am not sure if yall PC people have the same issue, but then you are probably using VS.
-
Dual Install Unity Most people don’t know, but you can have multiple versions of unity on your machine. First, uninstall all your Unity instances. Next, do an install of Unity 4.2.2 (anything that is before 4.3). Once you have done this, rename your unity folder. I just rename it to “Unity 4.2.2”. Now install the latest version of unity. So now, you have both versions of unity installed on your machine. The folders are “Unity” for the current and “Unity 4.2.2” for 4.2. Make sure update your shortcuts in your dock.
-
Link To The Old Mono In the current install of Unity, open the Unity preferences and go to External Tools (Unity → Preferences → External Tools ). There, select “External Script Editor” and “Browse…” to open a file window. In this window, navigate to Unity 4.2.2 and select mono from that folder. Close Unity and re-open just to make sure the changes stuck.
-
Modify Mono For Performance the old Mono on Mavericks had some performance issue but they can be overcome. Do this by disabling all the “Add-Ins” you don’t use, especially version control. The version control add-in has been known to cause issues. To get to the add-in dialog, navigate to MonoDevelop → Add-In Manager.
Now you are good to go. Maybe all you need now is a good MonoDevelop theme, learn how to make your own and get mine here. If anyone figures out the folding thing for MonoDevelop 4 on Mac, please let me know. I would love to try out the new Mono.
Update: 2014-10-24
After installing OSX Yosemite, I found that the old MonoDevelop does not work properly. Everything is cool except for the context menu that pops up when you hit “.”. I was able to cope for a while but then it just got super annoying. I rely on it quite a bit because my spelling is horrible. I have now switched to using Xamarin. Its basically MonoDevelop that ships with Unity but it’s code folding works. The only issue I have found is that its format settings are linked to the project and so you have to go in and define all your code formatting rules for each project. Once thats done, its actually great. I have had it crash once on me… but then I was doing a lot of weird stuff at the time :) Be sure to set it as your default code editor in the Unity → Preferences. Also, make sure to select the “Synch MonoDevelop Project” under the “Assets” menu in Unity when you switch/start a project. It just opens up the current Mono project in Xamarin for you and makes sure all your refs are sorted out. I have really started to like it so far. They changed the theme format from XML to JSON so here is the new Xamarin CM Theme!