MonoDevelop Roadmap

As stated on our public roadmap, we are shipping MonoDevelop-Unity 5.9 with Unity 5.3 in December. MonoDevelop-Unity 5.9 is at the time of writing the latest stable version of MonoDevelop and includes many improvements and fixes over MonoDevelop 4.0.1.

We have added a new workflow improvement to MonoDevelop-Unity 5.9. The target selection list is now populated with Unity targets, highlighted with an orange outline in the screenshot. MonoDevelop-Unity will now attach to the selected target with a single click on the “Run” button so you can avoid multiple clicks in the “Attach to Process” dialog when starting a debug session.

You can try MonoDevelop-Unity 5.9 today by downloading the MonoDevelop-Unity 5.9 preview builds from the forum. Feedback on the forum is more than welcome! MonoDevelop-Unity 5.9 is a drop-in replacement for MonoDevelop 4.0.1 and can be with used with Unity 4.6 and Unity 5, see minimum requirements in the forum thread.

Script Debugging Fixes

Besides upgrading MonoDevelop-Unity we have also been working on fixing script debugging defects in Unity that affect both MonoDevelop-Unity and Visual Studio Tools for Unity.

MonoDevelop and Unity REST Integration

Today the integration between MonoDevelop-Unity and Unity happens through the solution (.sln) and project (.csproj) files.

This setup is less than ideal since Unity needs to update the solution and project files each time you add, remove, move or rename script files in your project. Once the updated solution and project files have been written to disk, MonoDevelop then needs reload them. A better approach would be to have Unity communicate directly with MonoDevelop on each change to the file structure of your Assets folder and have MonoDevelop update accordingly.

Another issue with using solution files is that we are not using the same C# compiler when compiling your scripts in Unity and in MonoDevelop. This can lead to different compile errors and warnings in MonoDevelop compared to Unity, and in some cases scripts will compile in Unity but not in MonoDevelop and vice versa.

To address these issues and allow for a tighter integration between Unity and MonoDevelop, we are working on a new feature that makes MonoDevelop and Unity talk to each other using REST. What this means in practice is that MonoDevelop and Unity communicate directly with each other using a network socket and generation of solution and project files is no longer necessary.

Instead, MonoDevelop will display a hierarchy view of your Assets folder sent from Unity as a REST message. The Assets folder view in MonoDevelop will be updated on each change to your Unity Assets folder file structure. It will also be possible to add, remove, move and rename files in the MonoDevelop Assets view and the actions will be sent via to Unity to be performed. Once the file action have been performed in Unity, Unity will notify MonoDevelop of the changes to the Assets folder file structure and the Assets folder view in MonoDevelop will be be updated accordingly.

The screenshot below shows how the Unity Assets Folder view in MonoDevelop looks currently and is likely to change before release.

MonoDevelop will also use the REST service to compile your scripts in Unity and then Unity will send the build results back to MonoDevelop. The build results in the screenshot above were delivered to MonoDevelop from Unity.

The REST service is not limited to file operations and compiling your scripts. It can be used for any feature that is exposed as a REST endpoint in Unity.

Here are some of the features we have planned for the MonoDevelop and Unity REST Integration:

Just updated to Unity 5.3 and love it! My only issue right now is that MonoDevelop 5.9 is now no longer refactoring or using autocomplete. It drives me crazy! I’ve tried clearing out all the .sln files and all that from the project root folder but to no avail… super frustrating! Is anyone else experiencing this? If I set my IDE to a previous version of MonoDevelop (I think its 4.1) it works normally. What do I do!?

I just recently updated to Unity 5.3 which came with the update to Monodevelop (5.9). I now cannot do any debugging in UnityScript. My entire game was written in UnityScript. How can I fix this issue? I’ve tried installing and uninstalling a few times now to no avail.

I use IDEA at work and at home, it is very productive. JetBrains won’t deal with C#, because they sell ReSharper. I tried Consulo for Unity project, it’s really good. Also, it is a known fact that Googles’ Android Studio is based on IntelliJ IDEA.

Thanks for continuing to support/improve Monodevelop. I’m reading a disproportionate number of complaints about Monodevelop.

I’ve used to for several years now on a part-time basis and it’s been great. Autocomplete, refactoring and debugging all work as advertised. It does some funky magical renaming of scripts when you refactor the name of monobehavior classes. But once you get used to it, it’s pretty nice actually.

I tried VS with Unity. I’ve used VS a lot over the years for C++ and C# development but with Unity I found it was perhaps, overkill. Monodevelop gets out of my way and let me just code. So thanks for supporting it.

I just hope that someday you completely remove it. I’ve never had a good experience with monodevelop my whole career with unity. On every version bundled with unity its always been completely broken.

Obscure Error messages all the time. My scripts will randomly just not save and I don’t realize it until 20min of debugging when I decide to check out the file in another editor. It’s always been painful and unusable.

Right now I’m using Atom and without the integration my experience has been so much better.

Are there any disadvantages of using Xamarin Studio with Unity? I’ve been using that for some time now, and it seems to work fine together with auto-completion and so on, but at the same time I’m just scratching on the surface when it comes to scripting in Unity so there could be something missing I guess.

Xamarin Studio is a rebranded version of MonoDevelop. Xamarin work on the MonoDevelop source and then release MonoDevelop as Xamarin Studio along with their own add-ins. So MonoDevelop-Unity 5.9.6 and Xamarin Studio 5.9.6 are based upon the same source code.

It’d be great to document the debugger API along with the REST API so that other people could build integrations into better tools than MonoDevelop which has always been a pretty poor experience on OS X.

This is a very substantial announcement if properly implemented. If you guys really build out everything using RESTful web services, this opens the door for pretty much ANY tool to be integrated with Unity without having to worry about the integration of a UnitySDK or anything similar. I like where you guys are heading with this one because one could start building their own homegrown tools for Unity in a consistent manner.

Hopefully you guys will provide strong documentation for this (or at least stronger than what we got for uNet ;) ).

One more thing — would it be possible to be able to look at the Unity editor, including seeing the scene/game view, while stopped at a breakpoint in the MonoDevelop debugger? I don’t know how feasible this is, but that would be very useful! Even a non-interactive snap-shot of the game window before the break would quite useful.

This is an interesting idea, I’ve added it to my list of things to look into.

It will not be possible to view the editor/game view in the editor while debugging due to all managed threads being suspended. But we might be able to do something where you can request snapshots using the REST service and then display them in MonoDevelop.

I use Mono Development for debugging and this sounds like a nice set of improvements.

Please can you keep the sln/csproj as an option so that us vim users can continue to happily use omnisharp-vim for smart code completions? And of course publish the REST API so the vim community can eventually plug into that way of doing thing also.

No. This change does not change the .NET profile (version) supported by the Mono runtime in Unity. This is only an upgrade of the external MonoDevelop application and unrelated to the Mono/.NET version used in Unity.

.NET Profile Upgrade in Unity is currently on our Roadmap under “Research”.

Conditional breakpoints should already be working. You can right-click on a breakpoint in the breakpoints window and select “Properties” and then set a condition. Or right-click on a breakpoint on the line and select “Breakpoint properties”.

I honestly have no problem using monoDevelope but improvements are welcomed. I love the idea of writing my scripts outside the editor which gives me a whole lot of room for the game design which just feels awesome and natural. Thanks Unity ;)

I wish I could say I’m happy about this announcement, but I’m honestly not. I’m so not sure having such an intimate relationship with third-party editors like Mono-Develop and now Visual Studio on windows, is a good idea. My Reasons:

1.) Bloat: The current version of Mono Develop that ships with Unity is 333.5 MB (OSX version). Correct me if I’m wrong but I’m pretty certain most devs don’t use a much of the extra features that mono develop ships with.

2.) It’s not UnityLike: Unity prides itself in it’s Elegant UI. Mono develop in recent times has tried to be that but is still not quite there yet. It still does feel like a completely different app. The User Experience is not necessarily bad. It’s just very different from what we’re used to in Unity.

3.) Fragmentation: Unity now ships with Visual Studio on windows. It now has to focus on getting integration right on that front as well in addition to mono develop. Sounds like a wasteful use of dev resources.

4.) Integrated IDEs: Devs are buying ‘Script Inspector 3’ for an extra $55. If that does not tell you Mono develop isn’t well suited for the job, I’m not sure what does. in fact I suggest Unity acquire it and use that as the default. Double clicking a Unity script for another application to open just feels unnatural.

5.) Ownership: Unity should work more towards the ownership of the tools that come out of their box. By all means allow third-parties to integrate but leave them as third-parties. Owning most of the technology inspires confidence amongst your users. Because we know if there is a lingering bug we do not have to wait for some third-party to fix it.

6.) Debugging: The way script debugging in unity works right now is a pain. The scene being debugged is in one application (Or device) and the script is in another. Let’s not forget the profiler by the way, which sits in a different window from the script. Think of the pain devs go through when switching windows trying to find script bottlenecks. Basically if you don’t have 2 monitors, you’re screwed.

7.) Everything else is inside the editor: We call Unity an integrated dev. environment. This is almost true. Even the somewhat controversial service-oriented features are now build into the editor. Why is the one part of the tool where Devs spend quite a bit of time sitting outside the editor?

I could go on and on, but I kinda feel like this is a debate you guys are having in-house so I’ll just leave it to your better judgement.

1) The reason for the huge size on OSX is because we bundle the Mono framework with in the MonoDevelop.app. We do this to make sure that MonoDevelop always works regardless of whether you have the Mono framework installed in OSX or not.

2) We are working towards streamlining the MonoDevelop experience and if you have any suggestions for what could be improved let us know!

3) I think it is a good thing that developers have some script editor choices to choose from.

4) See another comment below regarding Script Inspector 3.

5) MonoDevelop is an open source app and even though we do not drive the development of it, we are actively working on fixing issues and improving the Unity development experience.

6) Having the debugger/code editor and your application as separate apps is probably the most common way of development. We are currently unable to provide debugging functionality in the editor. See Script Inspector 3 comment below for more details.

7) You could argue the same about any application that is used for creating assets used in Unity.

If you have any concrete suggestions or things you would like to have improved in MonoDevelop, please let us know so we can work towards improving scripting experience. Thanks!

Thanks for your responses.
With regards to point 7. You’re absolutely right. You could argue that. The only exception is that those tools don’t ship with Unity so why does mono develop have to ship with Unity? I guess you can again argue that if I don’t like it I can just delete it. But I don’t want to have to always download it as part of the editor whenever I do a QA update. A good compromise might be to treat it as a separate package during installation. Much the same way the Web Player and support packages are treated. My thoughts.

Using Unitycript makes no sense now. In my opinion, Unity technologies should give it up as quickly as possible. C# is a perfect language for Unity. For a bigger projects I prefer C++ that’s why I use UE4, but as soon as I get something to do with Unity, I will be using C# only.

This sounds very useful. Smart move using REST it would be awesome to be able to write editor extensions that could communicate with external apps, Adobe-CEP like extensions bring to mind all kinds of integration ideas.

I have been using Script Inspector 3 for about 2 months now, and feel that its a better script editor than Mono give or take a few issues with UnityScript. Are there any plans of Unity moving in a similar direction?

Script Inspector 3 is awesome, we have been playing around with it a bit internally.

However, there is a technical issue that is blocking us from providing such a in-editor solution as a replacement for MonoDevelop or any other external script editor. And that is that the Mono debugger works by suspending all managed threads when using breakpoints/stepping, including the main thread which the play mode/your scripts run in. This is what you see when Unity “locks up” when debugging. So it is currently impossible to provide a script editor inside the Unity editor that supports debugging.

Thanks Lukasz for trying out Script Inspector 3 and for liking it! I feel very honoured =)

I know about the technical limitations and I’ve been looking for various ways to overcome them. Your comment has actually inspired me to try a little bit harder and finally I managed to open a fully working and interactive Si3 window on hitting a breakpoint! And it runs in the same process, the one being debugged and the one which has all of its managed threads suspended… Which is pretty amazing and almost unbelievable but now it’s also proven to be doable, YAY! =)

See my post about that

This only shows that Unity is an incredibly powerful and fascinating engine since it allows such things to be done by 3rd party developers! And that’s why we all love it so much!!! :-)

We are implementing this a separate add-in for MonoDevelop, however due to some incompatibilities between the latest MonoDevelop debug client and the debug server in our Mono, it will most likely be necessary to use our build of MonoDevelop for full debugging support in Unity.

“Every time I edit the Compilation Defines in Unity PlayerSettings my Projects get rebuilt.” . . . I think I was not clear enough. :)

I meant the C-Sharp Projects get rebuilt.

So when I edit my Compilation Defines in Unity (of course Unity has to recompile). But when I switch to my Visual Studio Solution. Visual Studio tells me that my C-Sharp Projects got modified and have to be reloaded, resulting in a wait time. The same problem when adding/removing a Code File.

With the REST API and the UnityVS Extension it should be possible that Unity tells Visual Studio that the Compilation Defines have changed and then Visual Studio just adjusts the Project File instead of rewriting it from scratch. Just like when you edit the Compilation Defines directly inside Visual Studio.

We are actively working together with Microsoft to provide the best possible integration for Visual Studio as well. More details will be shared when we are further along in the development of the REST integration.