Author Topic: Alpha2.4(F3)(d-EVO)27-10-2008  (Read 1856 times)

Offline d-EVO

  • Bot Destroyer
  • ***
  • Posts: 125
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« on: October 27, 2008, 05:14:50 PM »
Code: [Select]
'My DNA code for an F3 Bot
'name : Alpha 2.4
'created by : d-EV0
'class : F3

cond
 *.nrg 5000 >
start
 100 .strbody store
 *.body 2500 >
 30 .repro store
stop


' TARGETTING ENEMY

cond
 *.eye6 *.eye2 >=
 *.eye6 *.eye3 >=
 *.eye6 *.eye4 >=
 *.eye6 *.eye5 >=
 *.eye6 *.eye1 >=
 *.eye6 *.eye7 >=
 *.eye6 *.eye8 >=
 *.eye6 *.eye9 >=
 *.eye6 0 >
start
 35
 .aimdx
 store
stop

cond
 *.eye7 *.eye2 >=
 *.eye7 *.eye3 >=
 *.eye7 *.eye4 >=
 *.eye7 *.eye5 >=
 *.eye7 *.eye6 >=
 *.eye7 *.eye1 >=
 *.eye7 *.eye8 >=
 *.eye7 *.eye9 >=
 *.eye7 0 >
start
 70
 .aimdx
 store
stop

cond
 *.eye8 *.eye2 >=
 *.eye8 *.eye3 >=
 *.eye8 *.eye4 >=
 *.eye8 *.eye5 >=
 *.eye8 *.eye6 >=
 *.eye8 *.eye7 >=
 *.eye8 *.eye1 >=
 *.eye8 *.eye9 >=
 *.eye8 0 >
start
 105
 .aimdx
 store
stop

cond
 *.eye9 *.eye2 >=
 *.eye9 *.eye3 >=
 *.eye9 *.eye4 >=
 *.eye9 *.eye5 >=
 *.eye9 *.eye6 >=
 *.eye9 *.eye7 >=
 *.eye9 *.eye8 >=
 *.eye9 *.eye1 >=
 *.eye9 0 >
start
 140
 .aimdx
 store

cond
 *.eye1 *.eye2 >=
 *.eye1 *.eye3 >=
 *.eye1 *.eye4 >=
 *.eye1 *.eye5 >=
 *.eye1 *.eye6 >=
 *.eye1 *.eye7 >=
 *.eye1 *.eye8 >=
 *.eye1 *.eye9 >=
 *.eye1 0 >
start
 140
 .aimsx
 store
stop

cond
 *.eye2 *.eye1 >=
 *.eye2 *.eye3 >=
 *.eye2 *.eye4 >=
 *.eye2 *.eye5 >=
 *.eye2 *.eye6 >=
 *.eye2 *.eye7 >=
 *.eye2 *.eye8 >=
 *.eye2 *.eye9 >=
 *.eye2 0 >
start
 105
 .aimsx
 store
stop

cond
 *.eye3 *.eye2 >=
 *.eye3 *.eye1 >=
 *.eye3 *.eye4 >=
 *.eye3 *.eye5 >=
 *.eye3 *.eye6 >=
 *.eye3 *.eye7 >=
 *.eye3 *.eye8 >=
 *.eye3 *.eye9 >=
 *.eye3 0 >
start
 70
 .aimsx
 store
stop

cond
 *.eye4 *.eye2 >=
 *.eye4 *.eye3 >=
 *.eye4 *.eye1 >=
 *.eye4 *.eye5 >=
 *.eye4 *.eye6 >=
 *.eye4 *.eye7 >=
 *.eye4 *.eye8 >=
 *.eye4 *.eye9 >=
 *.eye4 0 >
start
 35
 .aimsx
 store
stop

cond
 *.refeye *.myeye !=
 *.eye5 *.eye1 >=
 *.eye5 *.eye2 >=
 *.eye5 *.eye3 >=
 *.eye5 *.eye4 >=
 *.eye5 *.eye6 >=
 *.eye5 *.eye7 >=
 *.eye5 *.eye8 >=
 *.eye5 *.eye9 >=
 *.eye5 0 >
start
 *.refveldx .dx store
 *.refvelup 40 add .up store
stop

cond
 0 .eyefocus store
 *.refeye *.myeye !=
 *.eye5 6 >
start
 *.refxpos *.refypos angle .setaim store
 *.refxpos *.refypos angle *.refaim *.refvel mult 40 *.refxpos *.xpos sub 2 pow *.refypos *.ypos sub 2 pow add sqr div mult 60 *.focuseye mult mult .aimdx store
 *.refxpos *.refypos angle `(*.refaim *.aim sub abs mult) .aimshot store
 -8 .shootval store
 *.refshell sgn -1 add 5 mult -1 add .shoot store
 *.refvelup .up store
stop

cond
 *.eye5 0 =
start
 30
 .up
 store
stop

cond
 *.refeye *.myeye =
start
 140
 .aimdx
 store
stop

end
1:      2 is true
2:      1 is false

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #1 on: October 28, 2008, 09:46:19 AM »
cond
0 .eyefocus store
*.refeye *.myeye !=
*.eye5 6 >
start
*.refxpos *.refypos angle .setaim store
*.refxpos *.refypos angle *.refaim *.refvel mult 40 *.refxpos *.xpos sub 2 pow *.refypos *.ypos sub 2 pow add sqr div mult 60 *.focuseye mult mult .aimdx store
*.refxpos *.refypos angle `(*.refaim *.aim sub abs mult) .aimshot store
-8 .shootval store
*.refshell sgn -1 add 5 mult -1 add .shoot store
*.refvelup .up store
stop


You have a few problems in this gene from what I can tell :
- You have a store in the part of your gene that handles conditions. (0 .eyefocus store)
Also .focuseye is 0 to begin with, and since you don't store anything else in there then theres no point in storing a 0.
- You set your aim using .setaim, then you change .aimdx on the next line using some combination of the oponents aim and the distance and your focus eye...
It seems to me the second line isn't doing anything usefull, the first line setting .setaim is all you realy need to aim at an enemy, if the enemy is moving you will get the x and y pos of the next turn, so it will be easy to track using just the first line.
- You're using a negative shootval while using -1 and -6 shots. I'm not realy sure what happens from this, but I would sugest using a positive boost value for your -1 and -6 shots...
-.aimshot is spelled .aimshoot, but again theres no point in aiming towards your oponent and then turn away your canon to face the other way, so I would cut that line too.


Also I feel I should comment on a couple of things :
If eye5 is larger than 0 then there's something there, to check that it's larger than 6 seems a litle odd, since a value above 6 doesn't realy mean you're much closer than above 0...
You're tracking the oponents .up movement, but no sideways movement, it would be more effective if you also had a line to follow .dx or .sx movement.
And when you follow the oponents .up value you won't get any closer, so you may want to go faster untill you're within range of shooting...

So basicaly if I had to "refactor" that gene I would go for something along this :

cond
*.refeye *.myeye !=
*.eye5 0 >
start
*.refxpos *.refypos angle .setaim store
8 .shootval store
*.refshell sgn -1 add 5 mult -1 add .shoot store
*.refvelup 0 floor 10 add .up store
*.refveldx .dx store
*.eye5 30 >
*.refvelup .up store
stop

Offline abyaly

  • Bot Destroyer
  • ***
  • Posts: 363
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #2 on: October 28, 2008, 10:36:33 PM »
Negative shootvals boost shot range.
Lancre operated on the feudal system, which was to say, everyone feuded all
the time and handed on the fight to their descendants.
        -- (Terry Pratchett, Carpe Jugulum)

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #3 on: October 30, 2008, 06:38:36 PM »
Didn't know that... sound like it's very usefull for raping, Using -8 shots with boosted range and ties to force sexrepro
(Wish I had read this before posting Quickdraw, the whole point was to see how fast I could rape the alge, and -8 shot range was an issue, could have used smaller bots while raping and such.)

Offline d-EVO

  • Bot Destroyer
  • ***
  • Posts: 125
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #4 on: October 30, 2008, 07:13:32 PM »
Quote from: Moonfisher
*.refxpos *.refypos angle .setaim store
*.refxpos *.refypos angle *.refaim *.refvel mult 40 *.refxpos *.xpos sub 2 pow *.refypos *.ypos sub 2 pow add sqr div mult 60 *.focuseye mult mult .aimdx store
*.refxpos *.refypos angle `(*.refaim *.aim sub abs mult) .aimshot store

in case you havent been reading from the gene depository, this gene aims a head of the target by a certain depending on the targets speed and distance. Tought it would be usefull.

0 .focuseye is just a mistake. was fiddeling with different focus eyes and when that failed I changed everything back, except that

I said eye5 6 > because I only want to start shooting when eye5 6 >, because that is the range of .shot with -8 .shootval. The code to advance apon the bot is in the if eye5 0 > gene. so only crit once you have totaly read the bot and know what you are talkin about
« Last Edit: October 30, 2008, 07:23:51 PM by d-EVO »
1:      2 is true
2:      1 is false

Offline abyaly

  • Bot Destroyer
  • ***
  • Posts: 363
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #5 on: October 30, 2008, 11:28:11 PM »
I'm not sure if it works for -8 shots. It works for -1 and -6.
Lancre operated on the feudal system, which was to say, everyone feuded all
the time and handed on the fight to their descendants.
        -- (Terry Pratchett, Carpe Jugulum)

Offline Moonfisher

  • Bot Overlord
  • ****
  • Posts: 592
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #6 on: October 31, 2008, 05:07:00 AM »
As I think about it I'm not so sure it's even usefull... maybe for realy small bots, but they would usualy use mem shot anyway and you can't boost those...
Thing is I think the speed of the shot remain the same, so if you double the range of your shot you still have double the travel time aswell... so your shot isn't very likely to hit anything...
I can think of a few ideas where longer range with the same speed would still be usefull, but all of them involve mem shots so...
Would definately be worth a lot more if the travel time for a shot was constant, so boosting range also gave you faster shots.

Offline d-EVO

  • Bot Destroyer
  • ***
  • Posts: 125
    • View Profile
Alpha2.4(F3)(d-EVO)27-10-2008
« Reply #7 on: December 05, 2008, 04:10:58 PM »
Quote from: Moonfisher
As I think about it I'm not so sure it's even usefull... maybe for realy small bots, but they would usualy use mem shot anyway and you can't boost those...
Thing is I think the speed of the shot remain the same, so if you double the range of your shot you still have double the travel time aswell... so your shot isn't very likely to hit anything...
I can think of a few ideas where longer range with the same speed would still be usefull, but all of them involve mem shots so...
Would definately be worth a lot more if the travel time for a shot was constant, so boosting range also gave you faster shots.

that is a realy good idea. must post it in sugestions

would make predictive aiming much easier ( good or bad thing ?).
1:      2 is true
2:      1 is false