Author Topic: Viruses  (Read 5817 times)

Offline Elite

  • Bot Overlord
  • ****
  • Posts: 532
    • View Profile
Viruses
« on: January 23, 2006, 01:40:48 PM »
Anyone got any particularly interesting viruses to share?

This one has a timer, then kills its host (place any payload you like into the 100 .fdbody space, 500 is the countdown time in cycles)

Code: [Select]
cond
 878 8 !=
start
 *.thisgene .mkvirus store
 250 .vshoot store
 100 .fdbody *877 -500 add sgn 1 add 2 div mult store
 *.877 inc
stop

This one turns those infected into zombies, who work together to spread the virus

Code: [Select]
cond
start
100 .vshoot store
*.thisgene .mkvirus *.vtimer -1 mult 1 add mult store
676 .myeye store
676 *.memloc store
*.mkvirus 1 add  .delgene *.mkvirus *.thisgene sub dup mult sgn mult store
stop

This one messes up antivirus systems

Code: [Select]
cond
start
.vshoot inc
*.thisgene .mkvirus store
.delgene dec
stop

This one randomly overwrites the bot's memory

Code: [Select]
cond
start
.vshoot inc
*.thisgene .mkvirus store
32000 rnd 901 rnd store
stop

This one deletes all the infected bots genes (works against The One 50% of the time) but doesn't replicate
Needs a condition attached to stop it affecting the 'patient zero' bot

Code: [Select]
cond
start
 *.thisgene 1 rnd 2 mult -1 add add .delgene store
stop

This one breaks up MBs

Code: [Select]
cond
start
 *.thisgene .mkvirus store
 250 .vshoot store
 *.tiepres .deltie store
stop

Endless possibilities ...
(conditionless bots programming skills are good for this sort of thing)

Feel free to add some more viruses to this thread
- Kinda like a beastiary for viruses :firedevil:
« Last Edit: January 25, 2006, 02:08:21 PM by Elite »

Offline Light

  • Bot Destroyer
  • ***
  • Posts: 245
    • View Profile
Viruses
« Reply #1 on: January 23, 2006, 01:56:59 PM »
Have you tried any of them against furiae? not the greatest fighting bot in the world but a very good anti virus system  :D

Offline Elite

  • Bot Overlord
  • ****
  • Posts: 532
    • View Profile
Viruses
« Reply #2 on: January 23, 2006, 03:32:32 PM »
Cool. That's some nice coding.  :)  Una is immune to viruses too - it deletes them before they can execute (.delgene inc .delgene inc in an SG bot).
Ahh ... I see. The genes activate, but they don't execute if there's more than 6 genes - nice conditionless bot skills!  ^_^

Not even Supremus' viruses work against it. Unless the virus gets inserted after that last gene.

If Furiae can be made a better combat bot then it would have a real F1 advantage.

Hey, would .genes dec work?

 :idea:

EDIT: No, it doesn't. Hmm ...
« Last Edit: January 24, 2006, 11:52:46 AM by Elite »

Offline Endy

  • Bot Overlord
  • ****
  • Posts: 852
    • View Profile
Viruses
« Reply #3 on: January 24, 2006, 10:45:18 PM »
Try messing with thisgene. I seem to rember it having some effect.

Not 100% sure but I think a bot might be able to absorb multiple shots at once, potentially bypassing a antiviral defense.

Theres also a glitch(not combat legal) you can do to make super huge temporarily fast spreading viruses. If you delgene a previous gene being made into a virus the gene after it will be shot at the former's speed. Cool to see but not really legal to use -_-  :D

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Viruses
« Reply #4 on: January 25, 2006, 04:34:37 AM »
I may have fixed that bug for 2.4 BTW.

Offline Elite

  • Bot Overlord
  • ****
  • Posts: 532
    • View Profile
Viruses
« Reply #5 on: January 25, 2006, 12:31:42 PM »
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: [Select]
.delgene *.delgene *.thisgene sub abs sgn mult inc
Maybe like this:

Code: [Select]
cond
*.eye5 0 >
*.refeye *.myeye !=
start
*.refveldx .dx store
*.refvelup 30 add .up store
stop

becomes

Code: [Select]
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

with

Code: [Select]
*.delgene *.thisgene sub abs sgn -1 mult 1 add mult
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?
« Last Edit: January 25, 2006, 01:09:26 PM by Elite »

Offline Endy

  • Bot Overlord
  • ****
  • Posts: 852
    • View Profile
Viruses
« Reply #6 on: January 26, 2006, 02:14:48 AM »
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.

Offline Elite

  • Bot Overlord
  • ****
  • Posts: 532
    • View Profile
Viruses
« Reply #7 on: January 26, 2006, 11:35:44 AM »
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.) ?

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Viruses
« Reply #8 on: January 26, 2006, 01:40:07 PM »
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.

Offline Endy

  • Bot Overlord
  • ****
  • Posts: 852
    • View Profile
Viruses
« Reply #9 on: January 26, 2006, 10:03:35 PM »
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.
« Last Edit: January 26, 2006, 10:06:51 PM by Endy »

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Viruses
« Reply #10 on: January 27, 2006, 06:10:20 AM »
As I went to check I discovered that, like in previous versions, only conditions (=, >, etc.) and stores (inc, store, dec) cost nrg.  I just never got around to implementing the few lines for other DNA types apparently.