(For the full series, click here)
Life. What would we be without it. And what would crazy scientists be without trying to make it! The connection between dead materials and simple life are rarely taught, and even more rarely understood, but there are actually some fairly simple concepts to it. The common term for life being formed from dead matter is abiogenesis, and it has come a long way from mice being created by grain. But there are still, not surprisingly, a few steps between lifeless rock and people you see in the streets, and that might matter in certain games...
GENETICS
Genes are the basic building blocks of life. And the instructions for making it. They're pretty important. Which makes it insane that they are, chemically, not that freaky. The first genes we would likely recognize were made from two molecules connecting up: A phosphate (basically a phosphorus atom surrounded by oxygen atoms) and a sugar (a version called ribose, not the stuff we eat). The trick is, a phosphate can have a ribose on each end, and a ribose can have a phosphate on each end, so they can just make long string of phosphate, ribose, phosphate, ribose, etc. They can even lock the ends of the strings together to form a circle. But even moreso, the phosphates can have certain other molecules dangle from them, like those necklace chains with letters hanging on them. Four "letters" of interest were adenine, guanine, cytosine, and uracil, colloquially called A, G, C and U. And to complete the puzzle, G and C fit together, and A and U also do, though neither of them as strongly as the phosphate-ribose thing. So two chains of matching letters can zipper up. Or free letters can (and this is important) attach to a string and form a matching string. Since all these molecules are fairly simple to make, they were somehat abundant on early Earth, so they formed tons of different strings, which broke apart to form new ones. For millions and millions of years. All over (the oceans of) the world. Some 'folded', taking shapes that look like advanced knots, and those that folded in practical ways survived to make new copies. Thos copies snuck into little bubbles of naturally occuring fat and thus gained added protection. The results were cells, the building block of actual living creatures. And alng the way, ribose got upgraded to deoxyribose (the same, but missing one oxygen atom), which was tougher. It did use thymine molecules instead of uracil, though.
So that's where life starts. The copying of the better genes / cells plus occassional changes in the genes from a bad copy or chemical damage meant that every generation, the best copies survived, meaning they slowly got tougher. Evolution, baby! When things change around a large group of cells, those best fitted to deal with the change will survive and create new and improved copies. This is how life adpts to new places, and why different environments have different types of life. But wait, there's more! Genes actually do most of their work by connecting to bigger molecules, long strings of socalled amino acids, which are just twenty molecules that can connect just like the letters did (there are about 500, but the rest aren't used by genes). So genes grab amino acids and connect them in certain ways to form proteins, and proteins are used to make stuff in cells. And proteins even fold, too! This is the basis of how a living organism works.
The next great leap, of course, was cells that made proteins that glued them together. First thin film floated on the ocean surface, then tiny blobs of cells that allowed the outside ones to shelter the inside ones and make it safer for them to suck nice molecules from the water (eat, essentially). As these organisms evolved, their genes started having sections that only activated in certain parts of the blob, like at the tip of it or deep inside. This became the basis for organs and muscles and the like. The early organisms were likely just worm-like things stuck on rocks, then worms that could float around, then ones that would swim, then they grew bigger and became fish, some of which lived in shallow waters and evolved feet and used their air bladders (fish suck air into air bladders to control their bouyancy) to get oxygen in their blood from, well, air, making them able to breathe on land. Congratulations, life is now on land! Of course, other cells evolved differently and became plants and stuff.
CHEMOTAXI
No, not the foul-smelling cab you took home from that weird club downtown. Chemotaxi, essentially meaning "movement through chemistry", is a weird thing that even simple chemicals can do. We already discussed how polar and non-polar stuff hates one another, and this is sometimes seen by them "running away" from each other or towards one another. But the big boy version is when a cell makes proteins that get stuck in its outer 'skin', its membrane, and some of these proteins freak the hell out when certain chemicals touch them. The proteins then make the cell do a lot of different stuff inside, which sometimes ends in it spazzing out completely, or going totally mellow. This, as it turns out, is pretty neat! Many early cells no doubt just spazzed randomly, but if a cell evolved to, say, spaz out and move away from something dangerous, that cell would gain a neat advantage. If it mellowed out when there was useful molecules around but spazzed out when there wasn't, it would basically be hunting food; it would 'graze', mellow, in good places, and get the hell out of bad places!
Over billions (yes, with a 'b') of years, this became a key component in living things. The whole "molecules make proteins spaz out" is the core of your ability to smell, since molecules in your nose make proteins trigger cells to send a signal to your brain, so in essence, the cells in your nose are just outsourcing the whole spazzing out to other cells, first in your brain, then in your body. If you ever freaked out about someone else's onion fart and wondered why you would react so strongly to something essentially harmless, there you go. The modern rat's brain is about 40% built around just reacting to smell, so the heirs of early chemotaxi are thriving nicely.
PHYSIOLOGY
Over those billions of years, the ability to divide a body made of multiple cells (a multicellular organism) into specialized parts like organs and other things made what we typically think of as living creatures a posibility. But even humans are not just one cohessive thing; we are billions of cells cooperating, all trying to achieve something. The big difference from earlier life is that the cell doesn't create new copies and thus survive to evolve by strengthening itself, it does so by strengthening the overall organism. Like you! We all have cells flowing in our blood that act much like old-school cells, eating stuff that doesn't belong. We call it our immune system. We even have tons of tiny living creatures inside our bodies, helping us digest stuff or fight off really nasty things thaat get in. We call those our microbiomes. While immune cells are made by our body, microbiomes are things that copy themselves, not made by our bodies but handed to us from our mothers during pregnancy (very short version). Even creatures so small and simple that we can't see them with our naked eyes have complex systems of cells cooperating to keep them going. The kind of cells the way they cooperate, and what they end up doing, defines how a certain organism works, and what it can do.
A lot of this work inside the body is to send things through the body, to get it where it's needed. Immune cells, for example, are made inside bones (in the marrow), but have to go through the blood to 'patrol' organs for stuff they are designed to eat. Then the stuff that gets killed floats along and has to be cleaned out, and so on. Molecules are made in one organ to let other organs know what to do (hormones) and a ton of proteins function mainly to wrap up useful stuff in one cell and get it safely to another. And that doesn't even cover the more 'physical' things, like bone strength and the many cells that keep that up by essentially destroying and remaking your bones over an dover, constantly.
ECOLOGY
In many ways, ecology is the Big Picture version of what has already been described. Animals are systems of cells and microbiome organisms that work to keep the whole thing alive. This organism basically becomes a bit player in an even bigger organism, the local environment. Organisms grow as a biome around natural features like rivers and cliffs, becoming their own large system which evolves as organisms in it do. If a small rodent evolves into a big predator, it changes the ecological biome the same way a boosted immune system might change a single organism. And if the biome is weak, other biomes will take over and gobble up the terrain it wasted. Or maybe one biome even becomes predatorial against others, 'leaking' animals that break down the other biomes and allow the first one to take over their land. You may be thinking of swarms of locusts, and you wouldn't be entirely wrong.
This is something that is important to understand when studying sciences on a very large scale (i.e. lots of sciences together, interacting), the notion that something (like organisms) can be a reflection of something else, only bigger (like ecological biomes) or smaller (like a disease using an organism to evolve and spread). Like a Russian doll, systems act within systems, many using 90% or more of the same rules to function.
AS FOR THE GAME...
A while back (because life gets in the way, ironically), I posted an entry on artificial life simulation. The tl;dr is that it should be possible to make simulated cells with a certain, fairly limited, set of attributes, like speed, and have hundreds or thousands of numbered but nameless 'proteins' float about. Evolution would simply be to allow a cell to make one protein affect another inside it, and in the end, letting some affect the attributes. So when a cell touched, say, protein #5492, it triggered a chain that ended with its speed increasing for the duration, or with it making a few molecules of protein #10944 or something. Chemotaxis and basic survival should follow through simulated evolution, perhaps even basic multicellular organisms (cells syncing their speed due to triggering each other, or something). Now scale that up, and add a Factorio-style flow of proteins and cells through an organism, and pit those 'systems' against one another, complete with input from surroundings to simulate how well adapted an organism is to its (native or temporary) environment. There is a ton of complexity in that but a lot of it comes from the system itself changing and weeding out the unfit. The real problem is that coding this stuff requires setting the original parameters and waiting. You're not going to get a quick error message on any of it, you just gotta wait and see what it does, and then try again. Unless, of course, you are enough of a genius to make the code set up new parameters on its own. Then you basically have the system evolving new systems. Codeception. BWAAAAM.
What this could do for a game is finally get something like procedural generation out of the creative dumpster that is mixing body, leg, head, and butt type to create a new creature, like No Man's Sky does (did?). Creatures developed by this kind of system would be tuned to their environment and very complex. But of course, that complexity poses a completely different challenge, namely computation. If each animal in a game is a super-complex system of things interacting, just having two mice meeting in a field will burn down NSA-level supercomputers! Which is why some sort of black box algorithm is needed, code that sorts through what an organism's internal systems do and boil it down to key functions, at least when no active evolution is taking place. I mentioned the concept of a chemistry engine in this entry, and this is basically a biology engine. But a lot of the basic ideas are already finding their ways into games, like again Factorio, the notion of complex systems trying to manage a variety of tasks over extended periods of time. Have such systems play the game in auto mode, and assign ecological inputs (including inputs from other organisms), and you have a road map. It's a map for a very long and winding trip, but it's a map...
A note: Due to some disasters in my personal life (my dad is pretty sick) and the strain of my work with abandonned cats (we just rescued six tiny kittens and their mom, all of which occupy my hallway, making it a total of 19 cats under my care...), I haven't posted here in a long time. If anyone who followed the old entries on Science for Big Games reads this, let me know if I'm still hitting my old stride, or if I am out of shape, so to say. I likely won't post much in the near future, but I hope to slowly get back into the groove of things. Keyword "slowly".