Bots and Simulations > The Gene depository
Preditor effectivness gene for evo sims
EricL:
--- Quote from: Ispettore ---Is it possible to put the ratio myspecie\totalspecies in hunt genes?
--- End quote ---
Of course. The population control gene in the above post does exactly that.
Ispettore:
I mean, if I can put
*.totalmyspecies 100 mult *.totalbots div 5 <
in the shooting gene, example:
cond
*.eye5 0 >
*.refeye *.myeye !=
*.refeye 0 !=
*.totalmyspecies 100 mult *.totalbots div 5 <
start
*.refveldx *.body mult 1000 div .dx store
*.refvelup *.body mult 1000 div 30 add .up store
-1 .shoot store
stop
EricL:
Sure. You just did!
In current versions, the only thing you can't do in the Cond section is write to bot memory I.e. execute a store, dec or inc. (I may change this soon). You can read from memory just fine. The line:
*.totalmyspecies 100 mult *.totalbots div 5 <
reads from bot memory but does not store to memory, so you're golden.
Ispettore:
Thank you, I think this gene is very useful. But sometimes the bot keep shooting also if his pop is more than 5%... I must have put something wrong.
EricL:
If you catch a bot doing that, take a look at the .totalmyspecies and .totalspecies memory locations for the bot that is shooting (using the console of the bot properties dialog)and see if they are correct. Never know, could be a bug in the program. Either that, or you have another shooting gene somehwere (handling waste perhaps?) that isn't regulated by the population control...
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version