Bots and Simulations > The Gene depository
Viruses
Elite:
Look at Una's :D antivirus defence. Gene two is constantly delgened, deleting any virus before they can actually execute.
For some reason viruses are never inserted before the first gene.
How about each gene 'pass the .delgene' to the next gene with .delgene inc if they detect *.delgene = *.thisgene. Viruses be deleted instantly, as they cannot 'pass the .delgene' when they are inserted.
Put this code in each gene:
--- Code: ---.delgene *.delgene *.thisgene sub abs sgn mult inc
--- End code ---
Maybe like this:
--- Code: ---cond
*.eye5 0 >
*.refeye *.myeye !=
start
*.refveldx .dx store
*.refvelup 30 add .up store
stop
--- End code ---
becomes
--- Code: ---cond
*.eye5 0 >
*.refeye *.myeye !=
*.thisgene *.delgene =
start
*.refveldx .dx *.delgene *.thisgene sub abs sgn -1 mult 1 add mult store
*.refvelup 30 add .up *.delgene *.thisgene sub abs sgn -1 mult 1 add mult store
.delgene *.delgene *.thisgene sub abs sgn mult inc
stop
--- End code ---
with
--- Code: ---*.delgene *.thisgene sub abs sgn -1 mult 1 add mult
--- End code ---
Stopping the gene's normal functions from activating
Damn :angry:
Then the gene would never be able to execute :(
I'm sure I'm on to something here ...
At the very least you could periodically activate the 'pass the delgene' function to sweep out viruses. Or do it when *.genes changes.
A weakness of viruses is that they can't execute if they are .delgened on the very turn that they are inserted.
A *.refvirus would be good for telling when you are at risk of infection, then you can activate your energy-hungry antivirus routines.
If you want an (easier in some ways, but harder in others) virus-resistant bot, then brush up on your conditionless bots skills and make an SG bot.
Getting this 'pass the delgene' to work could make perfect antivirus possible. I don't even know if it works though. Could Numsgil or PY run through exactly what happens when you are hit by a virus, and in what order.
Can any of you do anything with this?
Endy:
I've worked on something similar. Couldn't get it working right since every single gene has to be active, a major nrg waste. :(
For a Multi-gene bot the first and last genes are the only ones you can be 100% sure of.
Elite:
Alternative strategy ...
... become a batterybot and make so much slime that viruses can't hit you :D ...
... and share it with your veg :)
How much slime do you have to have before viruses bounce off you (or go through you etc.) ?
Numsgil:
It depends on the strength of the virus shot. I'm not 100% sure on this but I think it's the number stored in .vshoot.
You'd have to go look at the source code to see the exact numerical relationship. It also depends on the virus's age, because shots lose strength over time.
Endy:
I think we could get this to work in the new version. Your questions about 'else' gave me the idea. If we have the .delgene stuff after both start and else it'll always be activated.
Only thing I'm not sure about is how costs for conditional activations are handled for else. If the same costs are charged as they would be for start. It would be slightly wasteful, but not as difficult as trying to have every single gene activate at once(the conflicting instructions the bots would face would be astounding :wacko: ).
About costs, I hope what I wrote above is how it is being done. Now that I'm thinking about it, the posibilities for misusing else are easy to see.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version