Getting Started With Game Design
When looking at a finished 3D game’s levels it’s often hard to visualize how they were put together, or which tools were used. The easiest way to understand the basics is to imagine building a house from scratch. You start off with the foundation, either the floor or a terrain mesh in the game. Then you add the walls and ceiling, the rest of the bits which make up the structure or organic environment.
I won’t go too far into the basics, so I’ll assume that you know a bit about vertices and 3D meshes already. There are two important things to keep in mind while putting a game’s level together: mesh and vertex count. When designing a level it’s a good idea to minimize the vertex count per mesh, say a wall or floor segment. Mesh count in a level is also important, as each mesh is rendered separately unless you’re doing batch processing on a number of identical elements, say a hallway filled with tiles. OpenGL allows you to render all those elements in one go, which is a lot more efficient. Don’t go overboard with this, though, as not everything you’re rendering may be visible and would be a waste of effort, lowering the frames per second (FPS) count.
Fortunately the latter detail should be taken care of by the game engine, and we got one. If it’s smart enough it’ll take care of such rendering issues for us, leaving just the vertex count issue. The number of vertices we can render in a scene on a given hardware configuration isn’t a static number, sadly. The applied textures, lighting and particle effects applies to the scene… they all take processing time away from rendering raw, unshaded vertices. To find out what level of vertices, texture detail and effects in a scene works best will be a matter of trial and error. See where it makes the FPS go below 25 FPS or whatever feels playable and tune down the level of detail until things go smoothly.
That about covers it for the basics of designing a game level… the exact looks of it will depend on the game’s setting, and the total size of a level on the maximum vertex count. In upcoming articles I’ll show some detailed examples of how to put a level together using a demo level.
Moving on to the next important step in designing a level, the level editor and mesh and map editing tools. What a level editor is I probably won’t have to explain too much. It’s where you take all the bits and pieces, put a mesh up somewhere, stretch and manipulate it until it’s the right size and shape and apply a texture and other maps to it.
A quick note about maps here, as they’re an essential part of making a level look more than just ‘nice’. They come in a bewildering number of types, including regular texture maps, bump maps, height maps, shadow maps, environment maps and so on. Each applies a different effect to a mesh, to colourize it, give it depth, allow it to be used for a terrain or so, give detailed shadow effects, or give the illusion of an environment reflecting in a surface. Sadly the Android platform is sufficiently limited that we can not use many of those maps, and especially not dynamic lighting. Look forward to a PC-oriented series of articles on more advanced object mapping 🙂
When it comes to creating meshes and maps, there’s a bewildering number of tools out there, both free and paid. Personally I use Autodesk 3D Studio Max 2010 and Adobe Photoshop Extended CS5. The former is good for creating meshes, the latter good for colourizing and creating other map types. For more advanced mesh editing and mapping work there are applications such as Mudbox (http://en.wikipedia.org/wiki/Autodesk_Mudbox) which can do things like 3D sculpting which is hard to do in 3D Studio Max and its direct competitor Autodesk Maya. You’ll soon find out that you’ll want to use more than just a few tools as each is better at certain tasks.
I have heard good things about Blender 3D as of late. Back when I first used it in 2002 or so it was absolutely unusable, with a user interface only its own developer could like, and which was less intuitive than Vi in general usage. Recently the UI has been completely redesigned, however, and should be a nice, free (open source) alternative to paid apps such as 3DS and Maya, both of which cost about 1,000 Euro a piece. For Photoshop I can’t really think of any good, free alternatives, though. The Gimp is extremely hard to use and will require a very steep learning curve, while still doing far less than Photoshop can do. Maybe find a used copy of Photoshop CS4, which isn’t that much of a step down from CS5. I’ll gladly hear of free alternatives you are using successfully. The best ones I’ll list in a future article 🙂
Next article should be more than just a wall of text. I’m currently quite busy finishing up this Android project for a client, which is taking away most of the time I could be spending on making fun Android games. Life just isn’t fair, is it?