Author Topic: futile cycle  (Read 3827 times)

Offline shvarz

  • Bot God
  • *****
  • Posts: 1341
    • View Profile
futile cycle
« on: May 25, 2005, 07:06:56 PM »
OK, this may sound weird, but I need a way for a bot to burn some calories without affecting/changing its general behaviour.  It should be some way to get rid of energy without producing anything back :)

Here is an explanation if that would make the problem easier:  I have my veggies limited to 300.  During the course of "predator-prey" cycles quite often the predator population drops down to a very low number and veggies start to reproduce like crazy, unchecked by predator.  By the time predator reproduces to any significant extent, the veggies have reached the max allowed number and can't divide anymore.  But they are still getting energy.  So, even though they are supposed to divide at 9000 nrg, they accumulate 32000 and when their population drops below 300 they divide again.  This totally knocks out the balance from the predator prey cycle and predator grows to huge numbers and eats all of the veggies.

So what I want is a gene that starts like this:

cond
*.nrg 1000 >
start

and then something that drops the energy of the bot by 1000 points, but is not revealed anywhere else in the sim.
"Never underestimate the power of stupid things in big numbers" - Serious Sam

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
futile cycle
« Reply #1 on: May 25, 2005, 08:11:41 PM »
here's what I would do:

cond
*.nrg 1000 >
start
*.nrg 1000 sub .mkvenom store
stop

cond
*.venom 0 >
start
*.venom -1 mult .mkvenom store
stop

Offline shvarz

  • Bot God
  • *****
  • Posts: 1341
    • View Profile
futile cycle
« Reply #2 on: May 26, 2005, 05:24:49 PM »
This works!  Thanks.

Except that it is .strvenom, not .mkvenom :)
"Never underestimate the power of stupid things in big numbers" - Serious Sam

Offline Endy

  • Bot Overlord
  • ****
  • Posts: 852
    • View Profile
futile cycle
« Reply #3 on: June 02, 2005, 09:04:50 PM »
I actually got annoyed that you can't unmake venom. I was trying to make a venom --> nrg feeder with the glitch and found that it wouldn't work.

Endy B)