Ok here’s the beginning of a CPA prototype, The system is hugely complicated. You can have a look at the code in the prototypes repo. I’ve split it into two pieces, the first, cpa1, has all the actual cpa logic in it and the second, viewer1, is just a load of pygame stuff to plot the graphs and isn’t really required.
So far I’ve only done “a species is made of organelles and they can do processes, species live in patches and have permeable membranes” there are also bacteria that live in the patches that break down proteins and agents that spill into the water. As you can see the graphs are crazy complicated (and also hard to read because the colours are so similar - not sure what to do about that). I’m going to keep working on it. I want to get this part really well balanced and sort out issues of storage and permeability being related to population number (a more populous species has a larger surface area), I haven’t even done compounds locked or blueprints yet.
Then there’s predation and then all the auto evo and inter-patch stuff on top of that. It’s a super super complex system. It’s got kind of ridiculous (and may need stripping down a bit because balancing something this complicated is going to be hard, but not impossible).
The graphs show the amount of compounds in a species (in relative terms, unlabelled axis, I might sort that out later). Species “-1” is the amount of compounds floating around in the patch. You can actually see some nice dynamics in the video. So every cell has a nucleus and that makes protein so that usually spikes at the beginning. But then the cell runs out of glucose and so the protein enzymes start to break down the protein again.
Oh and if you are going to run this thing yourself you will need to increase the run_time parameter, these graphs are for run_time = 10000, I set it to 100 because that way it’s easy to run it to check it works. Longer run times require more computation.
Before anyone tries to build this for real we need to have an iron tight, totally 100% nailed down list of compounds and organelles. Don’t even try without that as it very quickly becomes a nightmare.