Author Topic: Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)  (Read 3010 times)

Offline Welwordion

  • Bot Destroyer
  • ***
  • Posts: 325
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« on: November 23, 2007, 07:41:36 PM »
cond
*.robage 200 =
start
20 .repro store
stop

end

tested it in 2.43s did not work tested it in in 2.43 did work (and now I will stop test developing my bots in 2.43s ^^)
« Last Edit: November 25, 2007, 11:44:24 AM by EricL »

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
    • Games And Electronica
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #1 on: November 23, 2007, 09:55:09 PM »
Hey, don't give up already!  

Try removing the '='.

New rules in 2.43s; no logic operators.
"God is an ever receding pocket of scientific ignorence." - Neil DeGrasse Tyson

"God is a kid with an ant farm" - Constantine

Offline Welwordion

  • Bot Destroyer
  • ***
  • Posts: 325
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #2 on: November 23, 2007, 10:22:17 PM »
^^ good to know how exactly does that work? I mean > and < are also logic operators right?

And also there was some statement about conditionals within a genes body what does that mean?
And what are the operators True and False?

82) Conditionals are now allowed in the body of genes and can impact the success of memory operations within the gene body.
83) The commands True and False have been added.
« Last Edit: November 23, 2007, 10:25:03 PM by Welwordion »

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
    • Games And Electronica
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #3 on: November 23, 2007, 10:30:45 PM »
Eric or Nums can probably explain the details about the new way the DNA works, but I did a little testing here with your bot, and found I could as well delete the Cond statement instead of the = operator. Strangely, removing the cond statements didn't have any effect on my evobots, but removing the logic operators on them did.
"God is an ever receding pocket of scientific ignorence." - Neil DeGrasse Tyson

"God is a kid with an ant farm" - Constantine

Offline Peter

  • Bot God
  • *****
  • Posts: 1177
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #4 on: November 24, 2007, 08:04:55 AM »
Quote from: Testlund
Hey, don't give up already!  

Try removing the '='.

New rules in 2.43s; no logic operators.
Wh... what no logic operators, I hope you misunderstood something, this could mean the end of well functioning of many bots, certainly the majority of F1 and F2 and SB and MB(well mine the only that functions properly, right now), I got to check mine bots now, almost any bot uses logic operators.

Quote from: Welwordion
^^ good to know how exactly does that work? I mean > and < are also logic operators right?
Yes, correct, there are some more, I am not too sure about the statement of testlund, if it is true it is really drastic.

Quote from: Welwordion
And also there was some statement about conditionals within a genes body what does that mean?
And what are the operators True and False?
I think he means a gene in a gene with conditionals in gene body, hm wait I am goning to check that one, wasn't his already possible.
This is what I think.
In fact making an if insida an if.
Quote
if (true) {if (true){}}

Quote
Cond
Start
....Cond
....Start
....Stop
stop


Quote from: Welwordion
82) Conditionals are now allowed in the body of genes and can impact the success of memory operations within the gene body.
83) The commands True and False have been added.

The operators true and false, it is really a rather small fix.
Normally you have, well I take your gene.
*.robage 200 = gives a true when the bot is 200 cycles old(atleast it is supposed to do.)
1 gives always a true.

Quote
cond
1
start
20 .repro store
stop
Will always execute.
« Last Edit: November 24, 2007, 08:06:35 AM by Peter »
Oh my god, who the hell cares.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7718
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #5 on: November 24, 2007, 10:01:51 AM »
The changes to the way DNA works should be backwards-compatible for hand authored bots.  It's only evo bots, with their rather peculiar mix of nonsensical DNA, that would be broken.

If that first gene isn't working, it's a bug.

Offline Peter

  • Bot God
  • *****
  • Posts: 1177
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #6 on: November 24, 2007, 10:18:18 AM »
Quote from: Numsgil
The changes to the way DNA works should be backwards-compatible for hand authored bots.  It's only evo bots, with their rather peculiar mix of nonsensical DNA, that would be broken.

If that first gene isn't working, it's a bug.
Yes, there is somehow *.robage doesn't come over 200.

Still what has changed, wasn't it something like the stack is being reset at a cond statement, that case some hand-made bots could have a problem, just a few but there are some.
Oh my god, who the hell cares.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7718
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #7 on: November 24, 2007, 10:44:21 AM »
There are two stacks.  One is what we usually mean when we say "stack".  It holds numbers.  That one isn't affected.  The other is a boolean stack that handles conditions.  That's the one where changes have been made.  A cond resets the boolean stack (I think), but doesn't affect the integer stack.

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
    • Games And Electronica
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #8 on: November 24, 2007, 11:28:56 AM »
Quote from: Peter
Yes, correct, there are some more, I am not too sure about the statement of testlund, if it is true it is really drastic.

I expressed that a little bluntly, but the fact is that removing every logic operator on my Chainbot restored it to functionality, the same with my tiebot (both coming from the same zerobot ancestor), but it could very well be that I also caused some change in the bots behavior that I'm unaware of.

But removing some logic operators on hand written bots should stop some of there functionality, for instance the Animal Minimalis shouldn't be able to reproduce when it's above 10000 energy if it didn't have the '>' operator.
"God is an ever receding pocket of scientific ignorence." - Neil DeGrasse Tyson

"God is a kid with an ant farm" - Constantine

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #9 on: November 24, 2007, 09:20:56 PM »
Allow me to inject some clarity.

As Nums says, the new conditional paradym should be 100% backward compatable with hand authored bots.  People can code their bots as they always have without caring about or understanding this change if they like.  In particular, ALL EXISTING HAND AUTHORED BOTS SHOULD CONTINUE TO WORK AS THEY DID BEFORE.  If they don't, it's a bug.

The change in question is restricted in present versions to allowing the execution of conditionals in the gene body (the part after start).  There have been no changes to the conditional portions of genes (the cond part).  In particular, stores are still disallowed in the cond section.  Anyone wanting to better understand the new paradym should look here.

As Nums says, the gene in the first post of this topic should work perfectly as coded.   The new conditional paradym is orthoginal to this discussion.  It has no bearing on it. If the gene does not workas coded, it is a bug.  I will look into this and keep this bug open until I do.

Testlund is, um, mistaken.  Conditionals should not be removed from hand authored bots.   They do what they have always done.  They just do it in more places (they now work in the gene body and if present, impact what happens in the gene body).   Removing the "=" in the cond section of the gene above has nothing to do with the new paradym.  What it does is cause the gene to always fire since there is now no conditional logic in the cond portion of the gene, so it defaults to true.

If you have an evolved bot which evolved in a version prior to 2.43r, they way you preserve that bot's logc is to remove all conditionals from the BODY of it's gene(s).  In particular, if you managed to evolve a bot with a cond section that actually works, you SHOULD NOT tinker with it.  (And if you have actually managed this, you have won the Conditional Logic Prize).

A "cond" statement does indeed reset the boolean stack.  Nums is correct again.  It is important to note however, that a "start" does not.

True and False mearly push true or false onto the boolean stack.  I've updated the Wiki on these.
« Last Edit: November 24, 2007, 09:24:59 PM by EricL »
Many beers....

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
    • Games And Electronica
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #10 on: November 25, 2007, 02:57:39 AM »
Ok. Maybe I've crippled my tiebot then. Are you saying all 'cond' statements and 'logical operators' together form the conditionals and that they should be removed if they are in the body of the gene, which if I understand it correctly should be between a start and a stop command? Nums said just remove all logical operators and in my Chainbot you edited you removed all cond statements and logical operators.

Here's what my original tiebot looks like:

 1 mod mult & cond
 floor add angle >=
 or
 or
 & ~ store
 and
 cond
 start
 xor
 mult %=
 dec
 add 3 start
 angle 21 ~ 1 & mult *.setaim -6 sqr *13 - << mod >
 and
 xor
 -5 17 =
 >=
 !=
 floor angle rnd store
 31 store
 >> 5 <
 >
 mult 1 add else
 and
 store
 cond
 >
 >
 and
 *.up mult angle | *345 !~=
 angle dec
 angle ^ -1 div >
 - div xor
 store
 *.shoot << 2 angle =
 store
 6 * >
 dist else
 angle and
 cond
 ~ add store
 start
 *.up dec
 store
 or
 18 ++ store
 dec
 xor
 mult *.up *.hitsx mult inc
 add and
 & ceil <
 store
 !%=
 add - store
 .dn store
 .up store
 store
 <<
"God is an ever receding pocket of scientific ignorence." - Neil DeGrasse Tyson

"God is a kid with an ant farm" - Constantine

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
    • Games And Electronica
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #11 on: November 25, 2007, 03:41:50 AM »
And here's my new attempt to fix it:

 1 mod mult & cond
 floor add angle & ~ store
 cond
 start
 mult dec
 add 3 start
 angle 21 ~ 1 & mult *.setaim -6 sqr *13 - << mod -5 17 floor angle rnd store
 31 store
 >> 5 mult 1 add else
 store
 *.up mult angle | *345 angle dec
 angle ^ -1 div - div store
 *.shoot << 2 angle store
 6 * dist else
 angle ~ add store
 start
 *.up dec
 store
 18 ++ store
 dec
 mult *.up *.hitsx mult inc
 add & ceil store
 add - store
 .dn store
 .up store
 store
 <<

In any case the bot seems to work well.
"God is an ever receding pocket of scientific ignorence." - Neil DeGrasse Tyson

"God is a kid with an ant farm" - Constantine

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7718
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #12 on: November 25, 2007, 05:45:18 AM »
It's' unlikely that your zerobots were using conditions, so removing ALL the conditional operators fixes the problem of them suddenly working now

Of course, your DNA is now much shorter, so you might want to add in some 0s at the end or something to give them some more wiggle room.

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #13 on: November 25, 2007, 11:43:12 AM »
I have tested the gene in the first post in this topic and can find no bug.  The gene seems to work, the bot reproduces successfully at age 200.  I have also verified that the .robage memory location is working correctly.

Note that several things must be true for a bot to successfully reproduce:

They must have body > 2.
They must be older than 10 cycles.
There must be room in front of the parent for the offspring to appear.  A bot right up close facing another bot (or a shape) will be prevented from reproducing.

If you still feel there is actually a bug, please post a sim which demonstrates it.  Thanks.
Many beers....

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7718
    • View Profile
Simple repro or robage faulty? 2.43s RESOLVED (NO REPRO)
« Reply #14 on: November 25, 2007, 12:53:33 PM »
Quote from: EricL
They must be older than 10 cycles.

Is that new?