• Register
Post news Report RSS August Update - In-game characters and dynamic lighting

Monthly dev blog update covering character lighting and tools, as well as updates and modding of the map generator.

Posted by on

If you look back at the development progress so far, you'll see that most of the early updates were on designing and implementing a dynamic lighting system for the game engine. This month, it all comes together as dwarf characters can now be shown in-game with dynamic lighting applied. Read on to see how we did it!

Not only does the video show the dynamic lighting in action on the dwarves, but it also shows off the diverse range of looks that they can have. This is thanks to our character artist (who's also an animator) Dave Rigley, who produced a range of different body shapes, hairstyles and clothing styles for the dwarves. Better yet, there's a lot more still to come!

As you might have noticed, the hair and skin colors are also different between dwarves. To help prototype this, as well as ensuring everything looks correct when put together, we built a simple character viewer tool as you can see in action here:

In the video you can see switching choices between different parts of the character, as well as randomly picking colors for the hair and skin. In the bottom half of the tool, we're rendering the corresponding normal map for character which allows us to do the dynamic lighting (see our earlier dev blog for more information on that). Here's an example image showing what's going on:

character lighting

In short, an off-screen frame buffer has the normal maps rendered to it (top-right), and this is used in a shader to render the lighting information to another buffer (bottom-left), which is then combined with the color/diffuse frame buffer (top-left) to produce the final output (bottom-right). The plan is to have miner dwarves digging away in tunnels while carrying lanterns that give off these light effects, which should make for a much more atmospheric look than simpler lighting techniques.

The other big update is that the map generator featured in last month's update has been integrated to the main game engine, converting those procedurally generated maps into a map usable by the game engine. Here's a visualization of the transition:

There's still quite a few features to add - we're currently working on getting trees into the game and the river is probably the biggest feature which will be a bit further off. There's also plans for other greenery and more detail in the outdoor areas - the focus so far has been on the mountainside and its contents. You can try out the map generator directly in your browser (no plugins required) at mapgen.kingunderthemounta.in

One of the design goals of King under the Mountain is that everything is to be data-driven and open to modders. The types of rock and ore that are supplied to the map generator (as well as overall settings like its size) are moddable, and I'm going to cover the basics of this in an article soon.

As a closing note, don't miss out on our download mailing list at kingunderthemounta.in/download where we've decided to give the game away free to 1 out of every 10 subscribers. We'll only use this mailing list to let you know how and when you'll be able to get hold of the game (and no other marketing) - we hate spam too!

Post a comment

Your comment will be anonymous unless you join the community. Or sign in with your social account: