Difference between revisions of "Conspec recognition"

From WikiManual
Jump to: navigation, search
(Other RefVars)
m (Fixed typos)
Line 21: Line 21:
 
  100 .out1 store
 
  100 .out1 store
 
  stop
 
  stop
'''Step 1'''-Check In against out. note that if nothing is visible, the in values default to 0, which might screw up bot behaviour. It's usually best to add '''*.eye5 0 !=''' to be sure.
+
'''Step 1'''-Check In against out. note that if nothing is visible, the in values default to 0, which might screw up bot behavior. It's usually best to add '''*.eye5 0 !=''' to be sure.
  
 
  cond
 
  cond
Line 63: Line 63:
 
- Can't be tricked passively
 
- Can't be tricked passively
  
'''Disdvantages:'''
+
'''Disadvantages:'''
  
 
- Can be tricked if [[.myeye]] is altered by an info shot, [[venom]] or a [[virus]]
 
- Can be tricked if [[.myeye]] is altered by an info shot, [[venom]] or a [[virus]]
Line 78: Line 78:
 
- Rarer than [[Refeye and Myeye]] and so less likely to be targeted
 
- Rarer than [[Refeye and Myeye]] and so less likely to be targeted
  
'''Disdvantages:'''
+
'''Disadvantages:'''
  
 
- Most bots may only have one instance of the command in their DNA
 
- Most bots may only have one instance of the command in their DNA

Revision as of 20:40, 14 February 2014

Bots use various methods to identify others of their species.

In and Out

Bots can use the numbers stored in in/out to identify conspecs.

Advantages:

- Easy to implement

Disadvantages:

- Very, very easily fooled


Example: Step 1-Initialize IO port

cond
*.robage 0 =
start
100 .out1 store
stop

Step 1-Check In against out. note that if nothing is visible, the in values default to 0, which might screw up bot behavior. It's usually best to add *.eye5 0 != to be sure.

cond
*.in1 *.out1 !=
start
...

Memloc and Memval

Bots can use Memloc and Memval to read a location in another bot's memory. This can be used for conspec recognition.

Advantages:

- More secure than In and Out

Disadvantages:

- Can be fooled

Example: -Using the length of DNA as conspec Step 1: Set memory location to read to DNA length

cond
*.memloc .dnalen !=
start
.dnalen .memloc store
stop

Step 2: Read the value of the other bot's DNA length. This may not work if no bot is visible, so add *.eye5 0 != to be sure.

cond
*.memval *.dnalen !=
start
...

Refeye and Myeye

By far the most popular form of conspec recognition.

Advantages:

- Can't be tricked passively

Disadvantages:

- Can be tricked if .myeye is altered by an info shot, venom or a virus


Other RefVars

Other RefVars such as .refshoot can be used to identify members of your species too.

Advantages:

- Can't be tricked passively

- Rarer than Refeye and Myeye and so less likely to be targeted

Disadvantages:

- Most bots may only have one instance of the command in their DNA

Example:

-For all refvars, including .myeye; remember to check if there is a bot with *.eye5 0 !=.

cond
*.ref__ *.my__ !=
start
...

Other

Some other forms of conspec recognition have been thought up, but most are very impractical.