DarwinBotsManual
Open the app EspañolES

.refbody

The body of the bot you are looking at, from 0 to 32000: its size, and what you can take from it with a body shot.

Facts

Address
688
Name
.refbody
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, with the .body of the bot your focus eye sees, even if it is a corpse. 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 32000.
Mutations
picked as a read (*)

.refbody is the body of the bot your focus eye sees, what that bot reads in its .body. Almost all of its mass and its size depend on the body, and it is what a body shot takes (.shoot at −6).

A corpse keeps its real body (and its .refnrg), even though its DNA signature is 0. So something with body and .refeye at 0 is usually a corpse or a bot that doesn't look, like many vegetables. And body shots against a corpse pay off more than against a live bot (see Shots).

If you see nothing, it is 0.

' something big that doesn't read its eyes: I take body from it
cond
*.eye5 0 >
*.refeye 0 =
*.refbody 500 >
start
-6 .shoot store
stop