Author Topic: Help  (Read 3555 times)

Offline Panda

  • Global Moderator
  • Bot Destroyer
  • *****
  • Posts: 476
  • Computer Science Undergraduate (nerd)
    • View Profile
Help
« on: December 09, 2009, 03:03:30 PM »
I want these to work as an ecos system

Alga_Attach - Veggie
Leacher - Ties veggie
Leacher destroyer - Fires shots at both Alga_Attach and Leacher but keeps at a population low compared to the other population

I have not had much of the programming practice so I am just hoping for some help.
I am also hoping somebody could also help me make them more efficiant
The "Leacher Destroyer" is a cannibot which I do not want.


Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Help
« Reply #1 on: December 09, 2009, 05:38:02 PM »
The first gene in Alga_Attach.txt has an or.  This will basically resolve down to: TRUE OR your condition.  Which means that first gene will always fire.

That's the only thing that caught my eye as "wrong" from a high level point of view.  There are some inefficiencies in places, like Leach_destroyer's first gene where you could add a check to see if the values are set or not (and save the store cost per cycle).

Offline Panda

  • Global Moderator
  • Bot Destroyer
  • *****
  • Posts: 476
  • Computer Science Undergraduate (nerd)
    • View Profile
Help
« Reply #2 on: December 10, 2009, 03:50:07 PM »
Thanks, the leach-destroyer is a canni-bot when they are all in a sim together, can you help me on that

Update on all of them if I have changed anything

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Help
« Reply #3 on: December 11, 2009, 01:15:19 PM »

It has no conspec... so it has no way of telling friends from foes.
You have traces of a conspec, but you've outcommented all the lines.
It looks like it would work though.

This is your birth gene where the initial conspec is set up. You store the value 100 in mem location 50, and set memloc to point at location 50.

'(Memloc)
'cond
'  *.robage 0 =
'start
'  50 .memloc store
'  100 50 store
'stop

This means that memval will contain the value stored in the oponents mem loc 50, and comparing that value to what you have will reveal if it's a friend with the same key value (100) in the right location (50).
 '*.memval *50 =


As for making them more effective it realy depends on the goal. Since it's evo bots I'd say effective would be a strong conspec and a natural way of balancing the eco system (Focusing mostly on sim settings I'd sugest).
The problem is that a conspec that completely ignores anyone with the right key will make it very atractive to be a canibal, since noone ever defends themselves. In evo sims you'll often see bots back away from their own while shooting, this way if the "friendly" bot persues you it gets killed. Other than that balancing the different species would be more stable than restricting bot behavior in the code.
It's realy the same problem, code breaks more often than it evolves, and breaking restricting code is a benefitial evolutionary step. Atleast when the conspec breaks the bot tends to eat it's own young, so they also need to evolve into escaping when born, but a purely restrictive behavior will be very fragile against evolution and tends to break very fast.