Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Darwin226

Pages: [1]
1
DNA - General / Would this work?
« on: November 22, 2009, 07:53:33 AM »
I had an idea about eyes. It goes like this

Set eye 1 as focused eye
Check refs
Act accordingly
Set eye 2 as focused eye
Check refs
Act accordingly
Set eye 3 as focused eye
Check refs
Act accordingly

All in one gene. Would that work?

Also, what's wrong with this?

cond
 *.mode 1 =
 *.submode 1 =
 *.eyef 0 !=
start
 2 .submode store
stop

I used the console to test it mode was 1, submode was 1 and eyef wasn't 0 and it was all true but the gene didn't activate. Any thoughts?

2
DNA - General / Simple question about shots
« on: November 20, 2009, 11:29:12 AM »
I made a bot that feeds on plants and when it sees something that can shoot and isn't one of it's own, it fires a -1 shot with *.refnrg in shootval. It always kills instantly, so I was wondering, what kind of defense can a bot have against something like that if it doesn't even have a chance to react except for shell.

Any help would be nice.

EDIT: Just figured shell doesn't protect you from -1...

3
Newbie / Eyes
« on: November 05, 2008, 04:58:06 PM »
I've made a code that determines which eye has the greatest value and sets it as a focus eye.
This is it:

[div class=\'codetop\']CODE[div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']cond
*.mode 1 =
start
-4 .focuseye store
stop

cond
*.mode 1 =
*.eye2 *.eye1 >
start
-3 .focuseye store
stop

cond
*.mode 1 =
*.eye3 *.eye2 >
start
-2 .focuseye store
stop

cond
*.mode 1 =
*.eye4 *.eye3 >
start
-1 .focuseye store
stop

cond
*.mode 1 =
*.eye5 *.eye4 >
start
0 .focuseye store
stop

cond
*.mode 1 =
*.eye6 *.eye5 >
start
1 .focuseye store
stop

cond
*.mode 1 =
*.eye7 *.eye6 >
start
2 .focuseye store
stop

cond
*.mode 1 =
*.eye8 *.eye7 >
start
3 .focuseye store
stop

cond
*.mode 1 =
*.eye9 *.eye8 >
start
4 .focuseye store
stop

The problem:
It's 9 genes. Has anyone thought of something that has the same effect but it less genes?

If someone has, can I use it?


As usual, thanks in advance =)

4
Untagged bots / Hunter v.5
« on: November 02, 2008, 03:15:50 PM »
Here's my hunter. It's in 0.5 so it's still a work in progress.

I have no idea how good or bad it is.

[div class=\'codetop\']CODE[div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']'Hunter v.5 by Darwin226
'Hunts and kills everything that can shoot
'Now uses healing

Code: [Select]
def mode 50
def submode 51
def timer 52
def count 53

'Defines starting values on birth
cond
*.robage 0 =
start
1 .mode store
1 .submode store
stop

'The timer. IMPORTANT
cond
1 *.count =
start
.timer inc
stop

cond
0 *.count =
start
0 .timer store
stop

'Change direction ocassionally
cond
*.robage 100 mod 0 =
*.mode 1 =
start
140 .aimdx store

'S1
cond
1 *.mode =
1 *.submode =
start
15 .dx store
.timer inc
stop

'S2
cond
1 *.mode =
2 *.submode =
start
15 .up store
.timer inc
stop

'S3
cond
1 *.mode =
3 *.submode =
start
15 .sx store
.timer inc
stop

'S2
cond
1 *.mode =
4 *.submode =
start
15 .up store
.timer inc
stop

'T1
cond
1 *.mode =
1 *.submode =
*.timer 15 >
start
2 .submode store
0 .timer store
stop

'T2
cond
1 *.mode =
2 *.submode =
*.timer 15 >
start
3 .submode store
0 .timer store
stop

'T2
cond
1 *.mode =
3 *.submode =
*.timer 15 >
start
4 .submode store
0 .timer store
stop

'T2
cond
1 *.mode =
4 *.submode =
*.timer 15 >
start
1 .submode store
0 .timer store
stop

'Move out of the way
cond
*.eye5 50 >
*.refshoot 0 = and
*.refeye *.myeye != and
start
45 .shootval store
.sx .shoot store
stop

'Search and Destroy mode detection
cond
*.eye5 0 >
*.refshoot 0 !=
*.refeye *.myeye !=
*.mode 2 !=
*.out1 4515 !=
start
0 .timer store
2 .mode store
1 .submode store
stop

cond
*.eye5 0 >
*.in1 4515 =
*.mode 2 !=
start
0 .timer store
2 .mode store
1 .submode store
stop

'SD1
cond
2 *.mode =
1 *.submode =
*.eye5 0 >
*.eye5 50 <
start
 *.refveldx .dx store
 *.refvelup 30 add .up store
stop

'SS1 (Kill or Heal)
cond
2 *.mode =
1 *.submode =
*.eye5 50 >
*.in1 4515 !=
start
2 .submode store
stop

cond
2 *.mode =
1 *.submode =
*.eye5 50 >
*.in1 4515 =
*.refnrg *.nrg <
start
0 .in1 store
8 .submode store
stop

cond
2 *.mode =
1 *.submode =
*.eye5 50 >
*.in1 4515 =
*.refnrg *.nrg >
start
15 .dx store
0 .in1 store
1 .submode store
stop

'Prepare venom
cond
*.robage 20 mod 0 =
*.nrg 1000 >
*.venom 300 <
start
300 *.venom sub .strvenom store
.fixpos .vloc store
1 .venval store
stop

'SD2 (Kill)
cond
2 *.mode =
2 *.submode =
*.venom 50 >=
start
4 .submode store
32000 .shootval store
stop

cond
2 *.mode =
2 *.submode =
*.robage 20 mod 0 !=
start
5 .submode store
stop


'SD4 If you are ready to feed, paralyze the target
cond
2 *.mode =
4 *.submode =
start
-3 .shoot store
5 .submode store
stop

'SD5 Finally eat the pray
cond
2 *.mode =
5 *.submode =
*.refpoison 0 =
*.venom 0 =
start
-1 .shoot store
.oldven dec
stop

cond
2 *.mode =
5 *.submode =
*.refpoison 0 !=
*.venom 0 =
start
-6 .shoot store
.oldven dec
stop

cond
2 *.mode =
5 *.submode =
*.robage 1 add 20 mod 0 =
start
2 .submode store
stop

'Exit S&D if you don't see anything you would eat
cond
2 *.mode =
*.eye5 0 =
*.refeye *.myeye = or
*.refshoot 0 = or
start
1 .mode store
1 .submode store
0 .timer store
stop

'SD8 Paralyze the injured bot so you can heal him
cond
*.mode 2 =
*.submode 8 =
start
-3 .shoot store
0 .timer store
1 .count store
9 .submode store
stop

'SD9 Give him some of your energy
cond
*.mode 2 =
*.submode 9 =
*.timer 2 =
start
*.refnrg *.nrg add 3 div *.refnrg sub .shootval store
-2 .shoot store
10 .submode store
stop

'SD10
cond
*.mode 2 =
*.submode 10 =
*.timer 3 =
start
0 .count store
*.refveldx -2 mult .dx store
1 .mode store
1 .submode store
stop

'A small adjustment in turning
cond
*.mode 2 =
start
*.refveldx 3 div .aimdx store
stop

'If you have enough energy, make some poison
cond
*.nrg 1000 >
*.poison 50 <
start
50 *.poison sub .strpoison store
.shoot .ploc store
stop

'If you have enough energy, make some slime
cond
*.nrg 2000 >
*.slime 300 <
start
300 *.slime sub .mkslime store
stop

'If you get tied, free yourself
cond
*.mode 3 !=
*.numties 0 !=
start
*.tienum .deltie store
stop

'If you are full, make a fammily, tell them to wait till the tie is broken
cond
*.nrg 5000 >
*.mode 2 !=
*.mode 0 !=
start
3 .mode store
1 .submode store
0 .timer store
stop

'R1
cond
*.mode 3 =
*.submode 1 =
start
560 .aimdx store
50 .repro store
2 .submode store
0 .timer store
stop

'R2
cond
*.mode 3 =
*.submode 2 =
start
560 .aimdx store
1 .mode store
1 .submode store
stop

cond
*.body 300 <
*.nrg 300 *.body sub 10 mult 500 add >
start
300 *.body sub 10 mult .strbody store
stop

'WARNING Random crazyness
cond
*.hit 0 !=
*.hitsx 0 !=
*.hitdx 0 !=
*.hitdn 0 !=
*.hitup 0 !=
start
2 .mode store
7 .submode store
stop

'If you'r surrounded, start spinning and shooting. If you can't win, at least give them some fight >:-)
cond
2 *.mode =
7 *.submode =
start
90 .aimdx
-1 .shoot store
start

'If you are searching and you get shot, look at the target and eliminate it
'cond
'*.mode 1 =
'*.shflav 0 !=
'*.shflav -2 !=
'start
'*.shang 2 div .aimdx store
'2 .mode store
'1 .submode store
'stop

cond
*.shflav 0 !=
*.shflav -2 !=
start
1256 *.shang sub .aimshoot store
8 .shootval store
-6 .shoot store
0 .shflav store
stop


'Domination dance =)))))
cond
*.totalbots *.totalmyspecies =
*.robage 0 >
start
0 .mode store
0 .submode store
0 .timer store
8000 6000 angle .setaim store
stop

cond
0 *.mode =
0 *.submode =
*.hit 0 =
*.xpos 7000 <
*.xpos 9000 > or
*.ypos 5200 < or
*.ypos 6800 > or
start
15 .up store
stop

cond
0 *.mode =
0 *.submode =
*.xpos 7000 >
*.xpos 9000 <
*.ypos 5200 >
*.ypos 6800 <
start
628 .aimdx store
1 .submode store
stop

'Unstuck your self
cond
*.fixed 0 !=
start
0 .fixpos store
stop

'Call for help if injured
cond
*.nrg 500 <
start
4515 .out1 store
stop

cond
*.nrg 500 >=
start
0 .out1 store
stop

end
Hope you like him =)

5
Newbie / The body
« on: November 01, 2008, 05:34:06 PM »
Ok. I have several body related questions.

1. How is the actual body value calculated?
-Is it like energy?
If I have 1000 energy and get one more it's 1001, if I have 3000 energy and get one more I have 3001.
-Or is it more like eye?
Eye is 0, the bot get's a little closer and eye is 1. Eye is 50, the bot gets a little closer and eye is suddenly 3000 or something.
-See what I mean? Eye increases exponentially (I think)

2. What is the optimal body size?
-I want a bot that can hunt. That means I need a balance between movement and shooting.

3. What do you think is the best solution for eating swarms?
-I've seen a lot of bots that reproduce until they are really, really, really small (body 5 or less).
So now there's like 100 of them, everyone of them has 100 energy. 100*100=10000.
-I want to eat them but my bot has a lot of trouble hitting them.
I know I could think of something to eat them but how can my bot tell there is a whole lot of them?
He only has 9 eyes, which means he can see a total of 9 bots and there's at least 9 bots when he hits a group of veggies.
How can he tell if they are hostile or leafy?


Thanks in advance.

6
Newbie / Help
« on: October 30, 2008, 04:53:26 PM »
cond
*1 0 =
start
40 .aimdx store
1 1 store
stop


When I run the sim, this gene is always active. How can that be? In the condition it says to activate if 0 is stored in 1.
When it activates, 1 is stored to 1 but is still activates.

I think it's because location 1 is used by .up.

If that is the problem then can someone tell me which numbers can I use from my own memory?

7
Newbie / Update me, please
« on: October 30, 2008, 09:35:24 AM »
It's been a very long time since I played DarwinBots (is played the right verb?). There's been so much new stuff I'm completely lost.

Is someone would be so kind so explain a few things to me like:
What is the difference between native and non-native species?
What is voluntary movement?
Why is sexual reproduction used?
I've read that you no longer need cond line. ???
Why would older bot's act stupid in the newer versions?
Why is Wiki out of date (someone said it) when it's the first thing that pops up on Google when someone searches for DarwinBots?
What is focal eye?

There are only some of the questions. If someone has time to answer them, some extra information about the new stuff wouldn't be any harm....

Oh... Is there some guide that explains everything (how to write DNA and all the commands)?

P.S.
About the user name. I'm Darwin226 everywhere. It has nothing to do with DarwinBots.


Thanks in advance.

Pages: [1]