Bots and Simulations > Bot Tavern

Teriyaki (Taste like chicken)

(1/2) > >>

spike43884:
Teriyaki is my first bot that i've actually programmed (I wanted to add ties but the tutorial for that was no-where near as good as the advanced shotbot tutorial). There may be some bugs so i'd happily have them pointed out...I've been doing so much reading through code I started thinking I needed tea because my .nrg was to low  :blueblob:
Anyway...Heres the code for it

--- Code: ---'Teriyaki
'By: Spike43884
'Taste like chicken - Both .sexrepro and
'.repro in nessisary circumstances for
'amazing survival, will poop on enemies.
'Will incorporate -6 .shoot when I understand
'evaulating.

' Gene 1 Some stuff to do with poison

cond
 *.robage 0 =
start
 .shoot .eye5 .ploc store
 .shoot .shoot .ploc store
 .shoot .refvelup .ploc store
stop

' Gene 2 Food Finder
cond
 *.eye5 0 > *.eye4 0 > *.eye6 0 > or
 *.refeye *.myeye !=
start
 *.refveldx .dx store
 *.refvelup 40 add .up store
stop

' Gene 3 Mate Finder
cond
 *.eye5 0 >
 *.refeye *.myeye =
 *.nrg 15000 >
start
 *.refveldx .dx store
 *.refvelup 30 add .up store
stop

' Gene 4 Eat Food
cond
 -6 .shootval store
 *.eye5 50 >
 *.refeye *.myeye !=
start
 0 .aimshoot store
 0 .backshot store
-1 .shoot store
 *.refvelup .up store
stop

' Gene 5 Avoiding Family
cond
 *.eye5 0 =
 *.refeye *.myeye = or
start
 314 rnd .aimdx store
stop

' Gene 6 DONT EAT ME. I DONT TASTE GOOD!
cond
 *.poison 500 <
start
 50 .strpoison store
stop


' Gene 8 Shoot Sperm
cond
 *.eye5 50 >
 *.refeye *.myeye =
 *.nrg 15000 > *.nrg 30000 < and
start
-8 .shoot store
 *.refvelup .up store
stop

' Gene 9 Reproduce
cond
 *.nrg 15000 > 30000 < and
start
 10 .sexrepro store
stop

' Gene 10 Reproduce 2
cond
 *.nrg 30000 >
start
 10 .repro store
stop

' Gene 11 Poop on others Waste
cond
 *.waste 20 >
 *.eye5 0 > *.eye4 0 > *.eye3 0 > or
 *.refeye *.myeye !=
start
 *.refveldx .dx store
 *.refvelup 40 add .up store
stop

' Gene 12 Poop on others Continuted
cond
 *.waste 20 >
 *.eye5 50 >
 *.refeye *.myeye !=
start
 -4 .shoot store
 *.waste -20 .shootval store
stop

' Gene 13 Nobody to poop on CONSTIPATION Waste
cond
 *.waste 35 .
start
 .backshot inc
 -4 .shoot store
 *.waste .shootval store
stop

' Gene 14 OUCH! Nobody likes a bully.
cond
 *.shflav 0 !=
 *.shflav -2 !=
 *.shflav -8!=
start
 1256 *.shang sub .aimshoot store
 8 .shootval store
 -6 .shoot store
 0 .shflav store
stop

' Gene 15 Lets Get'em
cond
 *.shflav 0 !=
 *.shflav -8 !=
 *.eye5 0 > *.eye4 0 > *.eye6 0 > or
 *.refeye *.myeye !=
start
 .backshot inc
 -1 .shoot store
stop
end


--- End code ---
Ok, fixed a few errors.

Shadowgod2:
soooo many bugs with your bot.... i will get to them latter.

your current issue is you need to set your shoot aim. i think because you used backshot it set your shot aim to behind you but i will have to test this later.

i think you even doubled a gene in there "mate finder"

spike43884:
:o Oh yes.
Reproduction doesn't seem to be the main issue right now, but I will remove the 2nd mate finder...
So shootaim, how do I use that again? Only advanced shotbot tutorial and the basic bot tutorial were written in a way which, I was easily understanding :/

Shadowgod2:
in the feed gene put in

0 .aimshoot store
0 .backshot store

spike43884:

--- Quote from: Shadowgod2 on October 26, 2014, 04:41:27 PM ---in the feed gene put in

0 .aimshoot store
0 .backshot store

--- End quote ---
Added that and removed the 2ND mate finder...Going to test in a few *Ideal* conditions sims,
So if I set in 1 gene a aiming, I have to set specific aiming for each gene?
Surely I need to put that in the shoot sperm gene aswell?

You should write a few tutorials on the wiki, your actually quite helpful :P Maybe for each of the main functions (ties, shoot, aim, eyes, reproduce, move) and point out common mistakes by newbs like me :P

Navigation

[0] Message Index

[#] Next page

Go to full version