Okay, I now have this implemented using shot-based fertilization and Num's crossover algorithm. I want to bake it for 24 hours so 2.43.1 should come out tomorrow barring unforseen issues.
Bots can now shoot -8 sperm shots. There is no cost for this beyond the normal shot cost. The shooter's DNA is copied to the shot (like with viruses). .shootval operates the same way as for other shots.
If a sperm shot impacts a bot, it fertilizes it (shell, etc. has no effect on sperm shots). That is, the sperm DNA is copied to an internal buffer on the impacted bot. Note that the father need no longer be alive at impact time to father offspring. Once sperm is fired, the father is out of the loop.
Currently, bots remain fertilized for 10 cycles. We can change this easily down the road, but it's 10 for now. A new sysvar .fertilized (303) counts down the cycles remaining until the bot is no longer fertilized. If the bot gets shot with another sperm shot while fertilized, that DNA replaces the previous DNA and the .fertilization counter gets set to 10 again.
If a bot sets .sexrepro to a postive value not a multiple of 100 while fertilized, it will sexually reproduce (subject to the normal reproduction constraints w.r.t. body, space and vegginess) giving the offspring the specified percentage of it's resources.
For this version, the crossover variables mentioned in Num's algorithm are internal as follows. The minimum sequence length to match is fixed at 3 base pairs. The maximum number of crossover points is determined by taking the length of the shorter parent's DNA and dividing by 10.
Seems to be working pretty well now. Stay tuned...