Darwinbots Forum
Bots and Simulations => DNA - General => Topic started by: MrMound on April 19, 2005, 07:33:42 PM
-
could someone tell me how to make a virus that puts this gene into another bot?
cond
*.nrg 1 >=
*.refaimdex 2 =
start
60 .repro store
stop
:)
-
This post explains it pretty good (http://This%20post%20explains%20it%20pretty%20good).
Then you have *.thisgene, which works well in tandem with .mkvirus.
-
wich post? :huh:
-
Lol, my mind is going...
This post (http://s9.invisionfree.com/DarwinBots_Forum/index.php?showtopic=68&st=0).
-
so if it was gene 6 I wanted in another robot would the virus genes look like this?
start
6 .mkvirus store
stop
cond
.vtimer 0 =
start
-1 .vshoot store
stop
-
Not quite
You won't get anywhere with "-1 .vshoot store" since for vshoot, the stored number represents both the range of the virus shot and the energy cost to the originator.
Try something like "50 .vshoot store" to get a reasonable range for your virus. Yes it is expensive. It was designed to be. Making and shooting a virus should not be undertaken lightly.
-
so it would look like this?
start
6 .mkvirus store
stop
cond
.vtimer 0 =
start
50 .vshoot store
stop
-
That should do it.
Only one problem is that once one of your robots gets hit by one of its own viruses, the chance are that the intended gene (gene 6 that is) probably won't be gene 6 any more so the next virus sent out could be anything.
It gets really messy really fast
-
it doesn't work heres my bot and would you see if you see anything wrong with it?
I mean the virus
-
You have a misspelling. It's refaimdx, not refaimdex.
Also, and I quote myself in the now pinned virus thread:
vtimer is 1 when there is a virus ready to fire. 0 if there is no virus ready to fire, > 1 if there is still time left to wait.
.
-
When a robot doesn't work properly and you don't know why, pause the sim, double click the robot and look at its DNA.
Any misspelled words in the code will appear as zeroes because the interpretter cannot recognize them as commands.
This is a really good way to find problems quickly.
-
One more thing:
I strongly urge you to look into Spanish Conquistador's virus. I kid you not, that thing is a monster. A monster in its ability to leave SC unscathed. It's ability to kill off other species (even species with intelligent anti-viral genes). It's ability to create a self propogating virus that quickly takes over. It's masterful (if I do say so myself) use of the stack. It's definately the most deadly virus to date (deadly not because it causes instant kills (tried that, it wasn't as successful) but because it manages to leave the victim going for a few hundred cycles, reproducing like mad and creating new viral particles in each daughter cell).
-
sweet :D he used my simple bot to start whit :D
-
so are you saying it should look more like this?
cond
.vtimer 0 =
start
6 .mkvirus store
stop
cond
.vtimer 1 <
start
'donothing
stop
cond
.vtimer 1 =
start
50 .vshoot store
stop
:)
-
You've got the > and < signs confused, but other than that, yeah, looks good.
-
its not working still so could someone look at it and see if its my computer thats nat working or if its my bot? :)
-
You have a * in front of your .mkvirus address.
cond
*.vtimer 0 =
start
*6 .mkvirus store
stop
This is loading the current value of memory location 6 (aimsx) into .mkvirus.
Given the rest of your DNA code, this number could be anything from 0 to 1860 depending on earlier genes.
Drop the * and it works fine.
cond
*.vtimer 0 =
start
6 .mkvirus store
stop
Your main problem is that your robot has no defence against his own virus. The sim ends up in a right old mess of your robots violently reproducing and dying. Most of them have upward of 20 genes after a couple thousand cycles.
Adding genes to the genome (via viruses) tends to make your desired virus gene move to some position other than 6 so the viruses are all different. :blink:
Not a bad little robot actually. Without the virus he would do reasonably well in the lower part of the F2 league
-
Take a look at Spanish Conquistador, seriously.
-
Your main problem is that your robot has no defence against his own virus.
Adding genes to the genome (via viruses) tends to make your desired virus gene move to some position other than 6 so the viruses are all different. :blink:
cond
*.nrg 1 >=
*.refaimsx 2 =
start
60 .repro store
stop
your virus will only activate in bots that have 2 aimsx, which wont be many if you change it so it wont activate in bots with 1 aimsx (ie yours) it will affect almost all bots
cond
*.nrg 1 >=
*.refaimsx 1 !=
start
60 .repro store
stop
also if you move your virus gene to the begining of the code, so that it is gene 1, it will be much less likely to be moved when genes get added to the genome
-
Your main problem is that your robot has no defence against his own virus.
Adding genes to the genome (via viruses) tends to make your desired virus gene move to some position other than 6 so the viruses are all different. :blink:
cond
*.nrg 1 >=
*.refaimsx 2 =
start
60 .repro store
stop
your virus will only activate in bots that have 2 aimsx, which wont be many if you change it so it wont activate in bots with 1 aimsx (ie yours) it will affect almost all bots
cond
*.nrg 1 >=
*.refaimsx 1 !=
start
60 .repro store
stop
also if you move your virus gene to the begining of the code, so that it is gene 1, it will be much less likely to be moved when genes get added to the genome
Uh.... no!
That won't work at all Light.
*.refaimsx tells your robot how many .aimsx command the robot he is facing has.
I think you must have meant *.myaimsx
-
oops :redface:
-
the reason the bots good is I used the already made simple bot B)
-
thanks guys it works! :boing:
I owe you one :)