Author Topic: Detonator v1.2(F1)(bacillus)-24.04.08  (Read 2921 times)

Offline bacillus

  • Bot Overlord
  • ****
  • Posts: 907
    • View Profile
Detonator v1.2(F1)(bacillus)-24.04.08
« on: April 23, 2008, 07:56:16 PM »
Code: [Select]
'Detonator v1.2
'A vicious pack hunter
'Uses poison to make enemies overshoot
'Tries to kill any tie parasites

'Initialize bot
cond
 *.robage 0 =
start
 80 .out3 store
 80 .eye1dir store
 60 .eye2dir store
 40 .eye3dir store
 20 .eye4dir store
 0 .eye5dir store
 -20 .eye6dir store
 -40 .eye7dir store
 -60 .eye8dir store
 -80 .eye9dir store
 10 .eye1width store
 10 .eye2width store
 10 .eye3width store
 10 .eye4width store
 10 .eye6width store
 10 .eye7width store
 10 .eye8width store
 10 .eye9width store
stop

cond
start
 -4 *.eye1 sgn mult *.eye2 sgn -- abs mult *.eye3 sgn -- abs mult
*.eye4 sgn -- abs mult *.eye5 sgn  -- abs mult *.eye6 sgn -- abs mult
*.eye7 sgn -- abs mult *.eye8 sgn -- abs mult *.eye9 sgn -- abs  mult
4 *.eye9 sgn mult *.eye2 sgn -- abs mult *.eye3 sgn -- abs mult
*.eye4 sgn -- abs mult *.eye5  sgn -- abs mult *.eye6 sgn -- abs mult
*.eye7 sgn -- abs mult *.eye8 sgn -- abs mult add -3 *.eye2  sgn mult
*.eye3 sgn -- abs mult *.eye4 sgn -- abs mult *.eye5 sgn -- abs mult
*.eye6 sgn -- abs   mult *.eye7 sgn -- abs mult *.eye8 sgn -- abs
mult add 3 *.eye8 sgn mult *.eye3 sgn -- abs mult   *.eye4  sgn --
abs mult *.eye5 sgn -- abs mult *.eye6 sgn -- abs mult *.eye7 sgn --
abs mult add -2  *.eye3 sgn mult *.eye4 sgn -- abs mult *.eye5 sgn --
abs mult *.eye6 sgn -- abs mult *.eye7 sgn --  abs mult add 2 *.eye7
sgn mult *.eye4 sgn -- abs mult *.eye5 sgn -- abs mult *.eye6 sgn --
abs mult add -1  *.eye4 sgn mult *.eye5 sgn -- abs mult *.eye6 sgn --
abs mult add 1 *.eye6 sgn mult *.eye5   sgn --  abs mult add 0 *.eye5
sgn mult add .focuseye store
 .fixpos store
 6 .up store
stop

'Communicate coords and set timer
cond
 *.eyef 0 !=
 *.out3 *.in3 !=
start
 *.refxpos .out1 store
 *.refypos .out2 store
 10 .out4 store
stop

'Reset coord
cond
 *.eyef 0 =
 *.out4 0 = or
start
 0 .out1 store
 0 .out2 store
stop

'Transfer coords from other bots
cond
 *.in3 *.out3 =
 *.in1 0 !=
 *.in2 0 !=
start
 *.in4 .out4 store
 *.in1 .out1 store
 *.in2 .out2 store
stop

'No more food; explosive outwards movement
cond
 *.in3 *.out3 =
 *.out4 0 =
start
 100 .dn store
stop

'Aim towards food
cond
 *.out1 0 !=
 *.out2 0 !=
start
 *.out1 *.out2 angle .setaim store
stop

'Update
cond
start
 .out4 *.out4 sgn mult dec
 *.nrg 3 div *.body sub dup .strbody store - .fdbody store
 2 .strvenom *.nrg 100 floor 100 sub sgn mult store
 .paralyzed .memloc store
 -32000 .venval store
 .shootval .vloc store
stop

'Tie defense system
cond
 *.numties 0 >
start
 99 .shareslime store
 99 .shareshell store
 99 .sharenrg store
 1 .sharewaste store
 -1 .tieloc store
 -1000 .tieval store
stop

'Attack veggies more agressively
cond
 *.eye5 40 >
 *.out3 *.in3 !=
 *.refshoot 0 =
 *.refmulti 0 =
 *.reffixed 0 !=
start
 16 .shootval store
stop

'Feeding
cond
 *.eye5 40 >
 *.out3 *.in3 !=
start
 .up store
 -6 .shoot store
stop

'Fix veggies in place
cond
 *.eye5 40 >
 *.out3 *.in3 !=
 *.refshoot 0 =
 *.refmulti 0 =
 *.reffixed 0 =
start
 .shootval inc
 .fixpos .shoot store
stop

'Paralyze enemies
cond
 *.eye5 40 >
 *.out3 *.in3 !=
 *.memval 0 =
 *.refshoot 0 >
start
 *.venom .shootval store
 -3 .shoot store
stop

'Reproduce
cond
 *.nrg 200 >
start
 50 .repro store
stop
« Last Edit: May 07, 2014, 11:11:18 AM by Botsareus »
"They laughed at Columbus, they laughed at Fulton, they laughed at the Wright brothers. But they also laughed at Bozo the Clown."
- Carl Sagan