Bots and Simulations > Simulation Emporium
What do you make of this one?
Testlund:
The DNA is from the smallest veggie on the picture. Looks like they slowly has started to reproduce in a row. I think written DNA is difficult enough but evolved DNA is totally greek for me. I wonder if this one might show potential. It's evolved from a DNA with only 13 0's.
inc
*.shootval cond
dec
and
~ dec
start
>
<
store
*.timer inc
inc
*.shoot store
-12 *.dx !%=
and
and
add sub 1 2 %=
cond
dec
store
<< dec
add start
<
and
*.shootval cond
dec
and
~ dec
start
>
<
store
*.timer store
inc
*.dx store
-12 *.dx !%=
and
and
inc
sub 1 2 <
add add
Sprotiel:
I suppose you don't really care about this anymore, but since 2.42 evolved DNA is quite hard to decipher, it might be useful to show how it can be done. There are several layers of obfuscation which should probably be removed sequentially. First, you need to descramble 2.42's free form into its equivalent 2.37-like form. Adding a bit of markup to the code, you get this :
inc *.shootval
cond
and ~
start
store *.timer inc inc *.shoot store -12 *.dx add sub 1 2
cond
<< add
start
*.shootval
cond
and ~
start
store *.timer store inc *.dx store -12 *.dx inc sub 1 2 add add
First, you should find the flow commands. Everything before the first "cond" is ignored (white). Then "cond" puts you in "condition mode" (green), while "start" puts you in "body mode" (blue). You can now get rid of those commands which are inactivated when they appear under the wrong mode. They are the store commands in condition mode and the logic functions and comparison operators in body mode. So what's left would look like this in 2.37 :
--- Code: ---cond
and ~
start
store *.timer inc inc *.shoot store -12 *.dx add sub 1 2
stop
cond
<< add
start
*.shootval
stop
cond
and ~
start
store *.timer store inc *.dx store -12 *.dx inc sub 1 2 add add
stop
--- End code ---
To be continued...
Numsgil:
Written liek that, looks like it's another viral code. The similarity of gene 1 and gene 3 is my first indication. Given how different they are, though, I think the viral nature is rare and slow.
I think the operative line is *.timer inc. Basically every once in a while (very once in a while) something useful (a 1) gets written to various sysvars.
Testlund:
Well, that explains it a little, though I don't know how you know what commands to discard. When I see a bot do something new I usually take a look at the dna just to see if there might be a command there that triggers it, but it's hard to decipher. Also that the program prefers to use numbers instead of words for some commands makes it more difficult to understand, and I'm too lazy to search for it in the help file.
I have a better one here. This one I saved before they all died out. Then I started a new sim with 500 of this gene. It keeps up a stable population with slow reproducing veggies. Don't know if it whould survive if you put heterotrophs into the sim though, but it could be interesting to test.
0 0 0 *.up and
angle rnd store
inc
dup <=
sub *.up not
store
inc
rnd and
=
dup -218 dist *.robage angle angle angle store
angle ~ rnd <=
start
*-11 and
angle dup inc
*26 dup dist *.robage 0 angle mod <=
start
*.up and
angle rnd inc
sgn *.sx store
sqr *.robage dist 0 rnd =
*.up and
0 0 ~ *.up *-589 and
angle rnd store
inc
*-22 floor dup dist *.robage 0 rnd <=
start
*.up not
<
inc
=
-218 pow ^ *.robage angle angle angle angle 1 rnd ~ start
*-11 else
not
angle dup sub *26 dup dist *.robage 0 rnd ^ <=
start
*.up and
angle rnd inc
sgn *.sx dup sqr *29 dist 0 add rnd =
start
angle xor
*.up rnd 2 *.up dup dist >=
1 rnd <=
start
*.up and
angle 0 *.up angle ceil rnd store
inc
ceil dup dist *.robage 0 rnd <=
start
*.up not
store
rnd inc
=
dup -218 | angle store
~ -- pow dist inc
pyth *.up ceil mult *-164 *.robage cond
angle cond
~ -- pow dist cond
add *.dx ~ -- pow dist *.up angle not
~ -- pow <=
~ mult inc
2 add xor
*.dx *.up - xor
dist & cond
angle not
^ pow sqr cond
angle not
~ -- pow dist dist *-4 and
& =
cond
cond
++ *.sx dec
*.sx <
and
angle cond
angle not
cond
& pow dist inc
sqr *.up ceil mult *.robage cond
angle not
~ -- pow dist cond
angle not
~ -- pow dist cond
angle not
~ -- pow dist <=
cond
mult inc
2 add xor
4 *.up - xor
dist - cond
angle not
~ -- pow cond
angle not
~ -- pow dist dist *-4 and
& =
cond
store
>> 597 xor
dec
*.sx ~ and
angle cond
pow not
~ -- pow pyth inc
sqr *.up ceil mult *-164 *.robage cond
angle not
~ -- pow dist cond
angle not
~ -- pow dist cond
*.up and
not
~ -- pow dist <=
1 mult inc
2 add xor
4 *.up - xor
dist *.dn cond
angle not
~ -- pow cond
angle not
~ -- pow dist dist and
and
& =
cond
store
^ xor
dec
*.sx <
and
angle cond
angle not
~ & pow dist >
sqr *.up ceil mult *.robage else
angle cond
~ -- pow dist cond
angle not
xor
~ -- pow dist cond
angle not
~ -- pow dist <=
cond
rnd inc
2 add xor
~ store
*.up - xor
dist - cond
add !=
~ -- pow cond
angle not
~ *.aimleft pow dist dist *-4 and
& =
cond
store
++ xor
| *.sx >
<
and
angle
Sprotiel:
--- Quote from: Testlund ---I have a better one here. This one I saved before they all died out. Then I started a new sim with 500 of this gene. It keeps up a stable population with slow reproducing veggies. Don't know if it whould survive if you put heterotrophs into the sim though, but it could be interesting to test.
--- End quote ---
That's weird, it shouldn't do anything since it has no start after its first cond, and hence shouldn't execute any store command.
Navigation
[0] Message Index
[#] Next page
Go to full version