Darwinbots Forum

Bots and Simulations => DNA - General => The Gene depository => Topic started by: MysticalDumpling on February 22, 2014, 04:42:22 PM

Title: Powerful half-evolved shooting gene
Post by: MysticalDumpling on February 22, 2014, 04:42:22 PM
This evolved froma complex web of Blue On Blue evolution sims- whatever it is, it works well! I do not know how evolved it is, exactly.

start
*.eyef 0 !=
 *.refxpos *.refypos angle .setaim store
 *.refxpos *.refypos angle *.refxpos *.refypos dist 700 div *.maxvel mult *.refvelup add 9 floor *.maxvel mult .up store
 *.veldx .sx store
 -6 .shoot store
 *.nrg 50 div 20 floor 1000 ceil 15 store
stop

However, you have to add a conspec line to the top.

 :D
Title: Re: Powerful half-evolved shooting gene
Post by: MysticalDumpling on February 22, 2014, 04:43:55 PM
I found the original:

*.refxpos *.refypos angle .setaim store
*.refxpos *.refypos angle *.aim sub .aimshoot store
*.refxpos *.refypos dist 700 div *.maxvel mult *.refvel add 0 floor *.maxvel ceil .up store
*.veldx .sx store
-6 .shoot store
*.nrg 50 div 20 floor 1000 ceil .shootval store
Title: Re: Powerful half-evolved shooting gene
Post by: PhiNotPi on February 22, 2014, 06:54:06 PM
Okay, so I cut out all of the junk DNA.  This way, we can see what the DNA is actually doing:

Code: [Select]
start
*.eyef 0 !=
 *.refxpos *.refypos angle .setaim store
 *.refxpos *.refypos dist 700 div *.maxvel mult *.refvelup add 9 floor *.maxvel mult .up store
 *.veldx .sx store
 -6 .shoot store
stop

So, by comparing the two versions, we can see that the .aimshoot line was rendered nonfunctional, as well as the .shootval line.  Those are the major changes.  A third change was *.maxvel ceil changing to *.maxvel mult in one location. 

I can't tell if the *.eyef line was in the original or not, but I assume it was.