Sean Barton - Game Developer

Mega Man in Unity

16 March 2014

Hi there! This is an old post that may reference technology or views I now consider outdated - or maybe even a little embarrassing. Enjoy at your own risk.

Mega Man in Unity

After shipping Epic Mickey 2 (and before the heartbreaking closure of Junction Point Studios) I had a couple of months of comp time to unwind and sharpen the saw a bit.

I decided to spend my some time during that break getting to know the Unity game engine.

To be honest, I had to fight some strong biases in starting that exercise. I’m not sure how widely known the following sentiment is, but for programmers in big-budget, high-end AAA game development the idea of using an engine like Unity is considered weak sauce. Better to spend your time in C++ learning more about concurrency and data object model programming.

But I’ve been longing for some technology to help me prototype gaming ideas quickly and it sounded like Unity was the best contender.

I also decided that this would be the first time in my double life as a hobbyist game programmer that I was actually going to finish something. To that point I chose a beloved game from my childhood and decided to remake, in part, the original Mega Man from the NES golden days. I figured my love for the franchise would help get me past the eventual malaise that smothers every hobby project of mine once real life kicks in.

I’ve just recently finished the exercise and you can play the game in your browser here …

Mega Man in Unity

Only Cutman’s Stage

Like most old-time gamers I’ve spoken to, my experience with Mega Man started with Cutman’s stage — so that is the focus for this game. Other limitations on this Unity-powered game include …

  • Mega Man has no additional powers from any Robot Masters. The Mega Buster is his only weapon.
  • Enemies do not drop powerups, free lives, or any other items.
  • There is no scoring.

Obviously this is not a complete Mega Man game but fans of the original title will hopefully appreciate the 10 minutes or so of oldschool gameplay.

And fellow hobbyists might appreciate that this was accomplished with the free version of Unity.

Some Assembly Was Required

Still, with Unity being a 3D engine there were two important technologies I spent time on in order to display 2D assets:

  1. Sprites: I used the freely-available SpriteManager utility for sprite animation. In addition, I wrote a utility that took animations from GraphicsGale and generated code and data for each sprite.
  2. Tile-based Maps: I wrote a utility that transformed map data from Tiled Map Editor (a great little program for 2D enthusiasts, btw) into a Wavefront OBJ file that could be imported into Unity.

Ironically, I finished this project just as Unity 4.3 was being released so there’s a good bit of work here (especially with the sprites) I was planning to use for other titles that is now obsolete. That’s okay though as I’d much rather see sprites being first class citizens within Unity anyhow.

Was it Time Well Spent?

I started this project in December of 2012 and within a couple of weeks I pretty much had everything in place, with Mega Man running and jumping around Cutman’s level and a couple of the enemy sprites doing their thing. I was (and still am) pleased with how easy it is to work with Unity, even when you are trying to do something that game engine wasn’t really built for, like 2D sprite-based gaming.

After that short time I could have (and maybe should have) moved on to something original as the exercise of “learning” Unity was accomplished — but what I can say, I love that little Blue Bomber dude. I had fun with this.

How long did this take? It’s hard to say as I don’t do project management on my hobbies (what a depressing concept!). Yes, I started this nearly a year-and-a-half ago, but man, I also had to layoff some 30 of my closest programmer friends, shut down a studio, and find another job in that time as well. I only worked on this in spurts. Now, I’m just happy with the end result and I’m eager to focus on something else with my spare time. I hope some Mega Man fans give it a try and enjoy a small piece of nostalgia too.

And as far as Unity goes: I use it for all my hobby game programming projects now. I’d like to see the 2D components mature some more (Unity 4.3 is a great start to that) but overall I can’t think of any other (free) game engine that comes close to this one.


Hi! My name is Sean Barton (aka Seanba).

I’m an American-Canadian software developer working in Austin, Texas where I never have to shovel snow. :fire:

My career focuses exclusively on video game software and tools. You can read more about me here.


Aseprite2Unity imports sprites and animations for use with your Unity projects. Like all my tools it is available for free or name your price.

Get Aseprite2Unity.


SuperTiled2Unity is a collection of Unity scripts that import Tiled Map Editor files to your Unity projects. You can download for free or name your price.

Get SuperTiled2Unity.

(Note that regular Tiled2Unity is now deprecated.) :zzz:


Like my tools? Consider making a donation as a way of thanks!