On snail eggs

Even though I’ve had a functional breeding system in Gastropoda for a while, it still isn’t actually done. Most common snails do not give birth to live young…and definitely not to one live young. Initially it was good to just have the snails pop out one live baby snail so that I could properly observe and test the genetics and other attributes generated for the newborn. Now, however, with that being well on track, it is time to implement…egg laying.

The requirements were this:

At first I considered having a separate table for eggs, but then I decided not to complicate things. I added an eggLaid attribute to the snail table. By default eggLaid is set to false, so at the time of conception the snail-to-be exists but it doesn’t appear as an egg. The birthDate is NULL at this time. In the jar we can see the eggs displayed on top of the pregnant snail’s shell like so:

Pregnant snail

(The number of circles on the shell doesn’t represent how many eggs will actually be laid. In the future I’ll make this much more subtle, the quantity will be indistinguishable).

A LayEggs event is created in the db. Currently it’s always scheduled for exactly an hour after mating. When this event runs eggLaid is set to true in the snails table for those snails and they now appear as eggs (you can see an example of one of the eggs in the jar above). The color of the egg represents (to an extent) the shell color of the newborn, though without the pattern overlay it’s impossible to tell what the final snail will look like at this time. For me that’s pretty exciting, because I can come back in a few hours to start seeing what kind of shell pattern and eye color my baby snail is developing.

When the eggs are laid, a HatchEggs event is created. Eggs will hatch roughly 24 hours after they’re laid, but this will eventually have a tiny degree of randomization as well as be affected by factors like temperature and subtrate within the jar.

When the eggs are hatched, the snail is so tiny that you can barely see it. From there every hour the scale of the snail is increased based on the maturity rate attribute. Eventually the snail grows to its full size!

Up next I have to:

© - 2021 · Liza Shulyayeva ·