Bots and Simulations > Evolution and Internet Sharing Sims
help with code
(1/1)
shvarz:
Found this bastard in my evosim. How is he reproducing?
--- Code: --- pow >
*.nrg stop
>
and
start
65 300 *-321 store
and
1 4 *-25 angle rnd dec
7 8 *-386 *296 -17 .aimleft inc
else
-- -7 9 2 24 inc
56 -6 store
store
107
--- End code ---
I've seen it do it, and not just once - there was a whole colony of them.
shvarz:
BTW, what do these "stores to" and "reads from" negative memory locations do?
EricL:
Whoops.
I thought I was doing abs(n) mod 1000 for stores to negatvie mem locations but I missed a check in another routine. So, right now, the negative mem location is just dropped. It does not get put on the stack. So the line
65 300 *-321 store
is really
65 300 store
or
65 .repro store
As of 2.42.9k, it will instead be
65 300 *321 store
shvarz:
But that is going to kill my robot!!!! You bastard!!!!
EricL:
Think of it as a random mutation...
Navigation
[0] Message Index
Go to full version