Unity and MonoGame

There are plans to port my games to other platforms.  Windows is easy because my games already run on Windows.  XNA works great, you just have to remove the Xbox-specific stuff (related to the Guide and Gamer Services) and you’re good to go.  Unfortunately there’s no turnkey solution for the other platforms, so the porting process is going to be… more of a real port.

Today I investigated two options for this task.  First was MonoGame, basically a substitute for the XNA libraries that supposedly runs on Linux, OSX and iOS.  Sounds too good to be true, and unfortunately at this stage, it just doesn’t look ready.  To get a game to compile with it, I had to remove tons of code due to compatibility errors and missing API calls.  Even once I got through the compile errors and runtime errors, the game never managed to draw anything (though it could clear the screen to a specific color).  Plus the startup time for the application was about 5x compared to native XNA… so maybe there are workarounds, but so far it just doesn’t seem viable.

Unity is the other option.  Now a port from XNA to Unity is a major undertaking.  I got some serious protips from Brad who helped me through all those tiny things that trip up newcomers, and probably saved me a day’s worth of Googling.  The good news is I have a friend who knows Unity whom I can harass with my questions.  The bad news is that there will be some serious translation work to get my code from XNA to Unity.  I was hoping to put everything (my whole game) in one game object and let it draw itself, since I don’t need any of the high level features of Unity.  Just give me a surface to draw to.  Unfortunately it’s not so simple… exactly what this will take is something I’ll be discovering over the next few days.

8 comments

  1. I for one would LOVE to see soul caster 1 and 2 available on steam at some point. Def would buy them again.

  2. Thanks, I appreciate your support! As soon as I have something up and running, I’ll post about it here.

  3. If I can get a Unity port together, then touch/mobile platforms would be within arm’s reach. I wouldn’t release them without changing the control scheme to fit the new platform, though, so it would take a bit of redesign.

  4. Hi,
    I’m one of the maintainers of MonoGame, so would really like to know what areas you had problems with, so we can put it on the roadmap for others to benefit from. Please contact me and let me know what APIs you are using that you had issues with. Which platforms were you targetting? etc. Any information that will help us make MonoGame better is welcome.

    D.

  5. @Dominique, thanks for contacting me. I had attempted to contact a couple of the developers but it was hard for me to figure out who to email, so I don’t know if they ever got my messages.

    I was just targeting Windows at first. Within XNA, I couldn’t get drawing to work. My game draws to a smaller surface area then expands it to fill the screen. I couldn’t get this two stage drawing to happen: it would clear the screen to the proper color, but no sprites would appear. I would be happy to assist with the project, though, because it seems like a great idea.

  6. I didn’t complete a Unity port, I just dabbled in it a bit before going back to MonoGame. That’s something I’ll write about pretty soon here actually.

Leave a comment

Your email address will not be published. Required fields are marked *