Mapping The Surface Of A Video Game Moon

Writing for Hackaday isn’t all fun and games; occasionally I need to actually write posts and reply to emails from builders around the globe. Usually, though, I’m knee-deep in a personal project, or just hanging out playing a few video games. Recently I’ve gone off the deep end with Kerbal Space Program, an awesome little space flight simulator set in an alternate reality where everyone is just slightly incompetent.

As it turns out, there’s actually a lot of fairly technical objectives in this game, from performing orbital rendezvous to mapping the surface of another planet. It didn’t take long for me to go off the deep end and start mapping the Kerbal moon and turning it into a 3D object. Check out how I did this after the break.

Kerbal Space Program is a little indie space simulator where you manage your own space race. There’s no real object to the game; is a completely open sandbox where you build your own rockets, launch them into orbit, and hopefully make it to the moon. Think of it as a cartoony version of Orbiter and Eagle Lander 3D. To me, KSP is the perfect mix of the nerdtacular orbital dynamics, Hohmann transfers, and massive explosions.

There’s an amazing amount of user-contributed content for KSP. From 3D printed figurines to a bunch of additional rocket parts to an orbital laser, there’s a lot of fun to be had in this game. One of the most interesting add-ons I’ve found is [Innsewerants] satellite mapping module. The idea behind this mapping module is simple; just attach a radar dish to your spacecraft, launch it into orbit, and a .CSV file of altitude data is generated for celestial body you’re currently orbiting.

Here’s my satellite mapping probe orbiting Kerbal’s Mun

With the command-line tool included with the satellite mapping module, it’s very easy to generate topographical maps of the planets and moons in the Kerbal universe. Since these worlds are procedurally generated, it’s also the only way to do large-scale reconnaissance looking for flat landing areas. After parking my satellite mapping probe in a polar orbit around Kerbal’s Mun, all I had to do was sit back and let the data grow:

Yes, I cheated and put another probe at a 30° inclination to get more data from the mid-latitudes.

After a few days of watching my probe circle around the Mun, I had a fairly complete data set. Now, what to do with it? From the outset of my little topographical endeavor, I thought it would be cool to have a three-dimensional globe of this video game moon. I already had the tools to generate a greyscale height map; all I needed to do was make a 3D mesh out of this data.

I ended up using [William A. Adams]’s BanateCAD. It’s a tiny little CAD package reminiscent of OpenSCAD. There’s also an example of applying a heightmap to a sphere, so making a Kerbal Mun 3D mesh is as simple as changing a few lines of code.

The result of several days’ data collection from munar orbit

I haven’t gotten around to printing my Munar globe just yet, but I did put the .STL up on Thingiverse, along with the large versions of the color and grayscale topomaps. The data in those heightmaps isn’t completely accurate; despite the data file being about 400 MB, there were still a few small patches without terrain data. I filled those in with a judicious use of the Photoshop ‘smudge’ tool.

I’m also thinking about recreating the fabulous National Geographic moon poster (shown below) using the data from my Kerbal Mun probe. In any event, it was a fun project and a fantastic way to keep from having to deal with the regular Hackaday rigmarole.

24 thoughts on “Mapping The Surface Of A Video Game Moon

  1. “Recently I’ve gone off the deep end with Kerbal Space Program, an awesome little space flight simulator set in an alternate reality where everyone is just slightly incompetent.” How’s that an ‘alternate’ reality? Anyway your map sounds cool but could your CAD data be used with a 3D printer, you could hold Mun in your hand.

  2. First of all, niiiiiiiiiiiice. I got way into this game last summer and then stopped playing it when school started. I had no idea they’ve added so much new stuff since then.

  3. i played this for awhile while it was still in beta, i even started some mods. now i just need to scrounge up the 15 bucks for the newer version. it lets you do all the stuff you would do in orbiter with all those annoyingly complicated mfds, only visually.

    1. Launch, ascend to 10k meters, start pitching over to 90 degrees, cut engines when apoapsis hits ~80 km, circularize your orbit when you reach apoapsis, keep pitching prograde, when you see the moon rise from your orbit, do a TLI and get your apoapsis to about 10.8Mkm.

      Think of KSP as your practice run for notch’s new game.

      Also, if someone over at the KSP Forum can get an admin to send my user registration email over, that would be just super. brianbenchoff .

  4. So, what is the lowest orbit that is guaranteed to not result in an emergency lithobraking event? Before the terrain revamp I could get down to 800m circular, but now even 1800m seems too low.

    1. First off, apologies for the reporting of your comment; I clicked the wrong corner.

      In response to your question, the Munar surface reaches altitudes of almost 3400 meters near the poles, so 1800 is going to be cutting it a bit close, even in an equatorial orbit.

  5. You are my hero. I was heavily involved in the forum thread to determine (experimentally) the moon’s fundamental characteristics – namely mass – when it first appeared. This blows that away. I haven’t touched it much since then, but clearly the new scripting engine for parts has potential.

  6. Went to the Kerball website and they’re using a piece of commercial music on their promotional vid. A bit naughty and could get them in trouble. It’s off the album Geogaddi by Boards of Canada.

  7. I made the foolish mistake of playing this on a 2 year old computer. Seems pretty resource hungry, but it is a fun diversion for a while, before my graphics card eventually burst into flames.

    It’s a fascinating gameplay concept, even if the interface is a bit clumsy, I’ll definitely check back in a couple of years to see what it’s like when it’s finished.

Leave a Reply to lee cooperCancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.