Voxel Quest: January 2016 Update

voxel-quest-npcs

I completely failed to follow updates made to Gavan Woolery’s Voxel Quest in 2015, which is a real shame because it’s a very ambitious project that has seen significant progress since it first appeared about a year ago. So, for 2016, I’ll be giving it more focus…and fortunately, the good Mr. Woolery has begun 2016 with a recap of…well, at least the last few months of development that have gone into the game:

…since the last update, there was so much stuff that I could not even cover it all in the video, and I won’t cover most of it here.  But here is a high-level list:

  • More advanced building materials, building segment templates, building intersections
  • Physics (via Bullet Physics)
  • View distance now 16+ kilometers (formerly ~128 meters), and many rendering/generation tweaks
  • Networking (simple deterministic model over TCP, only good for low latency play over LAN)
  • Advanced pathfinding and basic character AI
  • Character generation and animation system (supports physical responses, blending, in-game pose editing and shape editing, support for objects, much much more)
  • Literally thousands of bugs fixed, many classes overhauled and cleaned up, several new utilities and more hot-loading for various resources.

The update also includes comments on what has gone right, and wrong, for the project over the last few months, and there’s certainly some interesting detail and introspection to be found in each section. For the purposes of reporting on the project, though, the later section concerning technical information seems more material:

The character animation system presented several new challenges. First of all, how do you efficiently ray cast with hundreds of dynamic limbs moving around on the screen? Well, limbs share a common trait: they are attached, and hence in the same proximity. So you only need to compute an intersection for one AABB (or sphere if you prefer) and that will let you know if you are anywhere near to hitting a limb in that body. Then you need not march into every limb of the body, but do an analytical prepass to determine roughly which shapes get hit, and collect some of them and march into those with a more complex algorithm. In this case, everything is just a line-line distance (one line being the view ray, the other line being the bone segment in question).

I had initial fears about passing in a bunch of bone data to the GPU, that the bottleneck would choke performance. But really its not so bad (really no different in practice than passing bone data to a vertex mesh), and you can animate a pretty large crowd – its not going to do Lord of the Rings scale battles, but that is ok (quality vs quantity).

Some of the biggest challenges came from trying to wrangle a physics system. There is a dichotomy between how the physics world wants to behave and how the user wants it to responsively react. This was compounded by trying to do complex animation systems with dynamically-oriented limbs over a custom collider for the voxel data of the terrain.

There are a number of images and videos to be found in the update, which ably demonstrate some of the features of Voxel Quest’s ambitious engine. Well worth a look!