Saturday 18 January 2020

How well can connected boxes learn to swim? The ecosystem game

Sometimes I play a computer game, mostly of the simulation type. While looking for something different from steering a European nation through history, or building a sprawling city somewhere, I came across a game promising to show biological evolution.

It would not be the first time a game tried to do that; Spore promised that too, and there are some others. I even wrote a post about Spore for this blog, because I was curious how the game designers dealt with the number of legs a creature might have. That number did not evolve by itself, but was chosen by the player. While the anatomy and movement of these legs were cleverly arranged, they turned out to be completely predetermined. In other words, the gradual changes in shape and capabilities of the resulting beasties had nothing to do with random variability followed by the environment pruning the stragglers, which is how real biological evolution works. Instead, Spore relied on Intelligent Design by the developers, and to a lesser extent by the player, acting as a minor deity.  

Click to enlarge; copyright Tom Johnson
But this ecosystem game promises the opposite. You get to play with a barren stretch of sea floor and have to turn it into a thriving ecosystem. The game will create swimming animals completely on its own, at first anyway. There is random genetic variability, and the unfit are weeded out, leaving their more successful brethren to forge on. You may wonder whether a full evolution simulation handled in this way would be any fun to play. After all, the premise would firstly be that genetic, anatomic and functional variability are all left to chance, and secondly that the environment provides all the selection pressures. What is left for the player to do?

In the demo, the player can indeed not control the characteristics of the beasts at all, but can guide evolution by altering the environment. The player has to place new plants or simple animals as food, and will also have to provide spawning areas and cordon off some pleasant mating grounds. Then you watch to see whether your Chosen Species rises to your challenge.

In the final game, there will also be a possibility to tinker with the anatomy of the beasts directly. An example of how that may look is shown above. Much as I like the idea of a fully independent evolution model, I also look forward to take up my duties as Minor Deity and start tinkering. In the full game you do not need content yourself with one Chosen Species; there will be various species, and herbivores as well as predators. At present, the game is in an early stage, so do not think you can lord it over a complex ecosystem just yet. That will be later. But a large part of the true evolutionary part is already in place. Let’s discuss the mechanics and the nervous systems of these beasts.

Tom Johnson, the creator of the game, provided some explanations. The animals consist of connected rectangular boxes of varying width, length and breadth. That’s it: they are boxes. That is what is shown in the video above. In the game, the animals look much nicer, as the boxes are depicted as smoothed forms with some nice fishy textures. At one end of one box there is supposed to be a mouth. To help the player, this part is shown as having a distinctively fishy head, with two eyes and two jaws. In a way this is a pity, as otherwise the animals have nothing that reminds you of a vertebrate. They are wholly and spectacularly asymmetrical! The boxes move at the connecting points, sometimes around one axis, sometimes around more than one. If one box moves with respect to another, this creates forces acting on the water around our hopeful monster. There is drag, there is angular momentum, and the creatures moves. Well, if you play the demo you will find that the earliest forms flop rather than swim and can be so painfully clumsy that they die before they even make it to any food.

The animals have nervous systems with an input layer, a layer for connection and integrationr (the Brain!) and a layer of output neurons controlling the muscles of each body part, which is, unsurprisingly, a box. You can actually see the neuronal connections in action, with impulses speeding along the axons (although at present the number of visible impulses does not reflect the true impulse frequency yet – for that you have to look at the number next to the neuron-). In successive generations, both the anatomy of the boxes and their nervous systems evolve. It is not quite clear to me yet whether the neural system develops at random or in response to mechanical needs. At any rate, I think it is an impressive feat to have both an evolving anatomy as well as an evolving brain linked to that anatomy.

Tom told me that the capacity of the evolutionary fitness principle was well born out by the game. At one point it turned out that some features of the animal worked only with a specific frame rate. In other words, the modelled animals had taken full advantage of one characteristic of their particular world, even though that was a completely unintentional one.

Another example is the animation above this paragraph: the animal seems to wave one limb in such a way that it acts as sort of propeller. In my searches for original means of locomotion to use on Furaha, I had tried to find a way to have a limb do just that. The problem is of course that in biology you cannot have a body part going through a complete 360 degree turn, as that would of be incompatible with blood vessels, nerves and muscles running to that limb. I could not see well enough how the movement worked, so I asked Tom. His reply was that I needn’t bother, as that was an early design, and he had not specifically stopped the animals from having continuous circular motions. So, again, blind evolution had used what it could and found a way...

Tom was kind enough to send me a unique illustration for this blog, shown above. The wrote: "This creature lives in the deep sea with a rocky, spiked terrain and evolved a nice downward glide to stick to the seafloor and eat the sessile creatures attached to it." I like it.

As I said, at present this game is available as a free demo, here or here. I will be keeping my eye on it, to see what strange forms can and will evolve. Charles Darwin once wrote the following about evolution:

 “There is grandeur in this view of life, with its several powers, having been originally breathed into a few forms or into one; and that, whilst this planet has gone cycling on according to the fixed law of gravity, from so simple a beginning endless forms most beautiful and most wonderful have been, and are being, evolved.”

Isn’t it fascinating that we can now see these principles in action, right before our eyes, on our computer screens?