A funny simulation of the typical claw machine, and, as the real one, will drain your credits if you are not careful! Get all the 30 available prices will you gain levels that unlock special abilities!
A Minigolf game with a very special style targeting iPod & iPhone plattforms. Play in a Mutant Jungle with carnivorous plants hungry for tasty golf balls, or in an abandoned Fair featuring a haunted castle, and more visually stunning locations!
I’m Rafa del Riego, Art Director at CrazyBits Studios. Now that A Mad Journey Minigolf, our first game for iPhone/iPod, has come to the end of it’s development, I thought that sharing some of the knowledge learnt with you will benefit both of us, especially if you’re a 3D artist or want to become one. In this post I’ll talk about how to light things up, given that light is, perhaps, the most important artistic feature one has to care about when it comes to recreate a world.
I won’t get into tedious explanation about light sensing, but ¦ have you ever heard about cones and rods? Human eye has about 5 million cone cells – color sensing – and about 90 million of rod cells – grayscale sensing. So, most of the information we see doesn’t need color at all, although color is almost a must. See the two images below, taken from the incoming promo video of A Mad Journey Minigolf (UPDATE: it’s already done: watch it here), and the final result.
Ambient Occlusion Pass
Default scanline pass
Ambient Occlusion multiplied with color
If you’re used to 3D modelling and rendering, I’m sure that you noticed that this was Ambient Occlusion and some lights affecting the scene. The point is that you’d probably have noticed that grayscale images have a lot of information: illuminance without colour is still very expressive!
Things this way are fine for current gen consoles and filming industry, but as long as real time needs for mobile platforms concerns, complex lighting is too expensive nowadays: we have to find workarounds to make the scene still visually atractive.
Level design can help to achieve realism, although as artists we won’t be designing so often (if ever at all). But we have in our hands one powerful, inexpensive and effective tool: vertex painting. With it, we can fake the lights, and give the scene that look & feel we have in mind. Vertex lighting (faking the lights by colouring every vertex, simulating real light), is the lighting of the poor. But it’s great anyway, as you may appreciate in this two images from a level of A Mad Journey Minigolf. The only difference between them is that one hasn’t vertex colour (first) and the other has. The latter is what you will see in the game. It’s not as complex and realistic as the previous Ambient Occlusion example, but the difference justifies the time spent.
Scene without vertex lighting
Scene with vertex lighting
Some background: vertex data includes 3D position, 2D texture coordinates and colour, and they are usually imported without problems in game engines; that’s why you get that fine result in the game. One benefit of it is that it’s almost inexpensive compared to other lighting techniques: all computation is baked into vertex data, thus saving CPU/GPU time as it avoids lighting calculations.
So, yes; the more the vertex, the more the detail the model has. And, yes again: we have a limit of vertices. Now the question is: how can we achieve a great result? In my experience, it’s best to drop some vertices from the the stuff (things on scene, decorative or playable, but not main characters, as they are too important), so as to expend them later in our terrain, the main receiver of light. It’ll improve the overall look. The key is to place the vertices in the mesh so the blending of colours truly represents the flowing of the light over the surfaces. It’ll usually require moving existing vertices in the mesh, but practice will give you fine guidelines as how to do it.
First version – Vertex light disabled
First version – Vertex light enabled
Fixed version – Vertex light disabled
Fixed version – Vertex light enabled
Take a look at the example. The mesh (our cave) is near a light source (a magic ball), but the vertices aren’t well distributed, so we see the light over a diamond shaped surface. After adding some vertices we have conducted the light. Of course, it’s an illustrative example, but shall do, as now the light propagates in a more realistic fashion.
Tools, please?, you might ask: Vertex Paint and Edit Poly modifiers, both included in 3D Studio Max. Every other 3D modelling program have similar tools, sure. With Edit Poly you modify the geometry (primarily the vertices in this case), and with Vertex Paint, you’ll paint every vertex.
Create the mesh of your terrain/stuff/etc, model it, do the texture mapping, and apply a Vertex Paint modifier. First of all, remember to set the Vertex color display – unshaded mode in the Vertex Paint dialog that appears (top left icon, marked in green in the image), as you will see the final result right into the editor. I recommend start flooding the entire mesh with the predominant color (shadow/light), and then painting the enlighted/darkened areas with brighter/darker colours. If you find that it looks overall brighter/darker than you want, add another Vertex Paint modifier and flood the entire mesh with black/white at, say, 10% of opacity, and see what happens. The same goes for globally changing the colour of the mesh.
3D Studio Max's Vertex Paint tool
One tip with 3D Studio: you’ll often find, after painting, that you need more vertices: add another Edit Poly modifier on top of your Vertex Paint. If you use one below, you’ll get unexpected (and undesireable) results, although you can use them to move the vertices without problem. That’s what I’ve done in the previous example, as you can see in the snapshot.
So simple that it’s amazing the great results it provides. There is other tip worth mentioning to bake lights automatically, but you’ll probably end up fixing the result: search for tutorials about Render to Texture and Bake Lighting, and you may learn more.
Lighting is a very complex field, so I have barely scratched the surface in this post, but I hope this is something worth reading for you. That’s all till the next time. Enjoy playing A Mad Journey Minigolf if you want to see our finished work, which includes some other uses of vertex lighting (the Ghost Wheel awaits you, the Haunted Castle, the Dwarf Mine, the Magic Hut ¦), and feel free to leave any comments/feedback/personal experience, we’ll appreciate it!