Author Topic: Sex repro  (Read 4664 times)

Offline jknilinux

  • Bot Destroyer
  • ***
  • Posts: 468
    • View Profile
Sex repro
« on: October 12, 2008, 01:07:25 AM »
Is it possible to make bots only reproduce through sexual reproduction? How?

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Sex repro
« Reply #1 on: October 12, 2008, 09:53:36 PM »
Well if you want to make sure the bot only reproduces with sexual reproduction then only use .sexrepro when fertilized (When the .fertilized counter is over 0)
And to fertilize a bot just hit it with a -8 shot...
You can also rape another bot by combining -8 shots with mem shots that force it to use sexrepro... like :
*.timer 3 mod 0 =
.sexrepro .shoot store
50 .shootval store
not
-8 .shoot store

Or you can force force the oponent to fertilize you if you're so inclined... for instance using venom that causes it to shoot -8 shots... if you can actualy call it venom when it's having that effect...

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Sex repro
« Reply #2 on: October 12, 2008, 10:26:01 PM »
Quote from: Moonfisher
for instance using venom that causes it to shoot -8 shots... if you can actualy call it venom when it's having that effect...


Offline jknilinux

  • Bot Destroyer
  • ***
  • Posts: 468
    • View Profile
Sex repro
« Reply #3 on: October 13, 2008, 12:30:42 AM »
Quote from: Moonfisher
Well if you want to make sure the bot only reproduces with sexual reproduction then only use .sexrepro when fertilized (When the .fertilized counter is over 0)...

That's not exactly what I meant. I am working on an evosim, but I couldn't find a way to force my bots to reproduce sexually. If I just hard-code it, it will break. I need a way to make it IMPOSSIBLE for ANY bots to reproduce asexually.

Offline bacillus

  • Bot Overlord
  • ****
  • Posts: 907
    • View Profile
Sex repro
« Reply #4 on: October 13, 2008, 12:42:58 AM »
How about using DNA scripts? "if robot DNA contains .repro", kill robot". this may of course play havoc with veggies.
"They laughed at Columbus, they laughed at Fulton, they laughed at the Wright brothers. But they also laughed at Bozo the Clown."
- Carl Sagan

Offline jknilinux

  • Bot Destroyer
  • ***
  • Posts: 468
    • View Profile
Sex repro
« Reply #5 on: October 13, 2008, 05:21:45 PM »
Quote from: bacillus
How about using DNA scripts? "if robot DNA contains .repro", kill robot". this may of course play havoc with veggies.

Is there a tutorial anywhere on how to write DNA scripts? I checked the wiki.

Also, does anyone have a veggy that uses sex repro? Or, is there a relatively easy way to make alga mini reproduce that way that I'm not aware of? Sorry if this is an obvious question...

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Sex repro
« Reply #6 on: October 13, 2008, 05:37:13 PM »
I don't think there's anything on scripts.  They might not even work anymore.

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Sex repro
« Reply #7 on: October 13, 2008, 05:41:57 PM »
Try something like this maybe...

[div class=\'codetop\']CODE[div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']cond
start
*.aim 40 add .setaim store

*.robage 0 =
300 .eye5width store

*.eyef 0 =
10 .up store
not
*.refnrg 6000 > and
*.refxpos *.refypos angle .setaim store
*.refvelup 5 add .up store
*.refveldx .dx store
-8 .shoot store

*.fertilized 0 >
*.nrg 6000 > and
33 .sexrepro store
stop
end

Offline jknilinux

  • Bot Destroyer
  • ***
  • Posts: 468
    • View Profile
Sex repro
« Reply #8 on: October 14, 2008, 11:19:53 PM »
Um, Never mind. I decided to look at the DNA script settings area, and it's pretty self-explanatory. Sorry about that. Thanks for the veggy, too!

Offline jknilinux

  • Bot Destroyer
  • ***
  • Posts: 468
    • View Profile
Sex repro
« Reply #9 on: October 25, 2008, 10:23:25 PM »
Quote from: Moonfisher
Try something like this maybe...

[div class=\'codetop\']CODE[div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']cond
start
*.aim 40 add .setaim store

*.robage 0 =
300 .eye5width store

*.eyef 0 =
10 .up store
not
*.refnrg 6000 > and
*.refxpos *.refypos angle .setaim store
*.refvelup 5 add .up store
*.refveldx .dx store
-8 .shoot store

*.fertilized 0 >
*.nrg 6000 > and
33 .sexrepro store
stop
end

Could you tell me how to change it so it doesn't use .up and .dx? I cant use the movement genes in my current sim. thanks!

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Sex repro
« Reply #10 on: November 01, 2008, 10:47:41 AM »
Well if .up and .dx don't work you can just remove those 2 lines, but other than that if you want your alge to move over to the alge it wants to fertilize then you need to do it with tie physics and such... not something I can whip up real quick
But they will still use sexrepro if the other bot is close enough to get hit... if you have gravity they'll all end up next to eachother and it's shouldn't be a problem...
Otherwise maybe you can tie and fertilize through the tie using -8 in .tieloc.... but I have no idea if this works... if it does then raping alge in the F1 league would be even more effective than I've thought up till now...

Offline d-EVO

  • Bot Destroyer
  • ***
  • Posts: 125
    • View Profile
Sex repro
« Reply #11 on: November 23, 2008, 04:31:01 PM »
Quote
The offspring's DNA will be a mixture of the DNA from each parent, constructed with an internal crossover algorithm.

Retrieved from "http://www.darwinbots.com/WikiManual/index.php?title=.sexrepro"

can someone please tell me what this algorithim is
1:      2 is true
2:      1 is false