DarwinBotsManual
Open the app EspañolES

.refup

How many times the DNA of the bot you are looking at writes to .up: one of the numbers in its signature, for recognizing species.

Facts

Address
701
Name
.refup
Kind
Sense: the engine writes it for the DNA to read
Group
What it sees (ref*)
Written by
The engine, in the actions phase of every cycle: how many commands writing to .up the DNA of the bot your focus eye sees has, whether or not they run. Also on colliding with a bot. You read it in the next cycle.
Cleared
The engine, every cycle, when the senses are cleared.
Range
0 to about 16000; 0 if you see a corpse or a shape.
Mutations
picked as a read (*)

.refup is the first number of the signature of the bot your focus eye sees: it counts how many times the address of .up appears in its DNA right before a write word (store, inc, addstore…). A bot with 5 .up store and 0 .up store gives 2.

Note that it counts what is written, not what runs: a gene whose conditions are never met counts anyway. And since .up is just the number 1, 5 1 store also counts. The number isn't recalculated every cycle: the engine derives it when the other bot's DNA changes (on load, at birth, on mutating or through a virus), just like your own numbers.

On its own it says little; its appeal is in comparing it with your own number, .myup, just like the other signature numbers (.refdn, .refsx, .refdx, .refaimdx, .refaimsx, .refshoot, .refeye, .reftie). If several match, it is most likely of your species. A corpse has its signature at 0.

' I don't shoot at what moves like me
cond
*.eye5 0 >
*.refup *.myup !=
start
-1 .shoot store
stop