It’s been awhile since we checked in with the programming side of things. I put out a call this morning asking “what would people like me to talk about?” Interestingly, the main thing was the UI, and how we’d make it Not Awful. We’re not talking about the context-sensitive UI because we haven’t worked out all the details yet, but we’re working on it. Instead, let’s talk about the general state of programming.
So what have we been up to over in Programmer Town?
It’s starting to look like we might actually be working on a game. This, personally, is one of my favourite parts of game development: when all the little abstract bits and pieces of art that you’ve been making since – well, since forever – start to snap into place and things start happening and looking pretty. What you see here, as always, is WIP shots from my screenshot directory.
Since we last left our heroes, a bunch of stuff has happened. Chris Whitman, who you may know from his work on Conquest of the Wizardlands, has been building a new, pretty interface for constructing buildings and workshops. You can now draw out a building blueprint:
Add stockpile designations:
Place additional modules:
and a building is created.
We’re still trying to suss out the right interface for selecting wall stylings, but that’s on the TODO list. You can even decorate it with windows, lamps, and other useful features.
Dynamics modules can be placed, and their inputs and outputs are previewed.
(We’re actually in the middle of a knife-fight in THE PIT about exactly how much we want the user to plumb things in themselves, and whether or not giant cities full of terrifying amounts of piping are, in fact, fun. They’re certainly visually pretty.) Anyhow, here you get a Steam Turbine with two inputs for Steam and two outputs for Mechanical Force. Maybe you want to hook them up to some more menacing pipes at some point, I dunno.
You may also have noticed that our building footprints are now a lot more complicated than the last ones that we showed. Most of the exploding building bugs have now been – thankfully – resolved. We still have a few issues where the odd triangle is flipped incorrectly, and so it doesn’t light up right, but I’m hoping to resolve that soon enough. If you look closely, you can see it in the shot with the lanterns. We also added support for rigid body animation, which means that our steam turbine has nice moving gears that correctly turn the shadows around, that sort of thing.
Chris also added support to our widget library (Illusion) for transparent widgets, changeable fonts, skinning, motions, and motion tweening. We’ve added the ability for objects in the world to have tooltips. This is in preparation for the big context-sensitive UI push, which David says I shouldn’t talk about until it’s in and we know if it works.
I have mainly been alternating between character code, tool improvements, rendering improvements, and management. Enough work on the character code has been done that people will now get their jobs, go do them, and wander back home to their stockpile. The basic framework is done, but there’s a lot of fiddly little programming to handle all the special cases (eating crimble, consuming Laudanum, going mad) and making sure that people know when they might want to do those things.
I also put in a new water renderer one day, which you can see in these pictures, because the old horrible one was annoying me. This isn’t final, but it looks much better. We added ambient light – dynamic lights for lanterns and explosions are coming as soon as I have a spare day – and made the ambient occlusion term a little less moody, so that humans were not surrounded at all times by terrible clouds of awful darkness. In general, the game sort of feels like “oh, I might want to play this!” and not “oh dear, look at all the awful things.” That’s good news.
This bug, from a rewrite of the texture code, was Bad News. Bad news, in this case, took the form of Terrifying Plant People.
The other nasty bug we had, which caused no end of trouble throughout all of last week, was a random crash bug. After much intensive debugging, and no end of swearing, we finally figured out what the problem was – when the queue of messages between the renderer layer and the gameplay layer overflowed, the memory copying would randomly destroy a large chunk of memory. (Unlike Dredmor, where we do the rendering and the gameplay on the same threads, CE keeps the rendering tasks and the gameplay tasks in separate threads and they communicate via a message passing interface.) Tracking this one down was not fun.
Micah has been busy working on the networking side of things recently, and we’re on track to have a first pass of that done by Christmas. All the socket stuff has been done for a long time, thanks to Ryan; we’re only just now getting it plumbed into place. Ryan, meanwhile, has a first pass done of the new dynamic music system. This is very interesting, and we’ll see how it turns out; we track six moods (ambient, productive, discovering, battling, tragedy, insanity) and combine various audio tracks to better reflect the mood of the game.
So, yes. Everything’s chugging happily along. If anybody wants me, I’m going to go get some more coffee now.