Underneath Creatures 4, like in previous episodes, there’s an entire matrix of codes and parameters that determine the behavior of Norns and their interactions with the eco-system. Today, we’re going under the hood to delve deeper into the mechanics and the inner-workings of a Norn, and present you with an overview of the in-house tools we used to debug our little creatures’ behavior.
In the making of Creatures 4, the main challenge resides in the fact that every time you implement a new feature, or change the way the Norns behave just a tiny bit, you need to go through hours of play-testing to make sure you didn’t mess up the complete balance of the game, that the various scenarios remain bug-free. This, knowing all the way that you can never truly harness a Norn’s behavior, since it’s conditioned by countless personal and environmental factors.
To this end, our tech wizards have developed several tools to monitor and debug our implementation of the original Creatures AI. As we established in previous posts, moving the Creatures engine to 3D proved to be a more daunting task than expected, for which we needed constant access to a certain set of variables.
Over the past year, our programmers have spent a lot of time on in-game debugging tools that help our game designers track the Norns’ attitudes as well as their environment. You’ll find some exclusive screenshots of these debugging tools here below.
The standard Creatures 4 in-game view, free of debugging clutter:
This view informs us about the status of our crowd management system (avoiding collision between agents) as well as the physics for each agent in the world.
Most agents in this demo-screen have been put in “custom” state which basically means they are doing something script-specific and do not belong in special groups like physics or crowd.
Attributes and Scripts
Opposite to what all the visual clutter would have you believe, this is one of the most informative views. It shows many properties for each agent: attributes, instinctive/genetic behaviors, category, running script etc. All this determines what a Norn can do with each agent in the world (e.g. an attribute sets a flower as eatable by a Norn).
Norns have several facial expressions that inform the player on their current status or mood. Facial expressions are triggered by a sum of parameters that determine which expression has the higher “weight” and should therefore be displayed. This algorithmic approach makes the process slightly more opaque than simple “Norn is happy –> happy face”. What expression is displayed when a Norn is both happy and hungry? Which has priority between hunger and sleepiness?
While some choices are obvious (pain often wins), some are not. Hence, the debug options!
The Norn’s focus and path are partly driven by its senses. Sight, hearing and smell play an important role in an agent catching the Norn’s attention.
Below you can glimpse at a Norn’s sight and hearing ranges, represented by the blue and green outlines respectively.
Each ray tells the ability for a Norn to see each agent. If the line is white, the agent can be seen; if it is red, rather not. The environment’s geometry is taken into account to compute this: in this case, most visible agents are on the same height as the Norn.
Hearing range is pretty self-explanatory.
This picture below shows the smell propagation. In Creatures, smells are called Cellular Automata (CA). Technically speaking, CAs are not exclusively used for smell, they can be means to other ends, such as giving the Norn a sentiment of “being at home”. Still, most of the time we use them for smells and to be honest, we still have to tweak a lot of them.
The propagation display is made of small spheres: you can see some spheres fading out on the border of the screen… At those spots, the potency of the smell is lower.
Outside the game, a handy webpage allows us to monitor the Norn’s drives and decisions. We can also access all this data in the game itself, through the science kit, but this raw and dry mode makes batch-processing tasks much more efficient.
Please note that, like in previous installments of the series, each Norn still has a set of organs that simulate its digestive system and comes into factor to determine when a Norn contracts an illness. They also carry an artificial “brain” so to speak, and are interiorly affected by over 150 chemical elements. And of course, genomes enter into play as much as before, naturally – After all, Creatures is essentially a Genetic Game, we’re kind of going all-in on this particular aspect Our next blog article will actually focus on that: genes and what you can do with them, breeding, splicing – Endless possibilities really. If you didn’t catch it yet, we’ve released a teaser pic of various breeds on Instagram earlier this week!
If you recently tried to comment to our blog articles in the section below and found yourself stuck because of not having an account, please note that guest-commenting was disabled by mistake earlier (we omitted to toggle an option off during our Disqus plug-in implementation)… Guest posts are now enabled again! So if you don’t like sharing private information at the same as your opinions, you can take it easy and feel free to speak out anonymously again!