.hitang
A sysvar that exists in name only: the engine never writes it, so it works as free memory.
Facts
- Address
- 221
- Name
.hitang- Kind
- Free: it has a name, but the engine does not use it
- Group
- Collisions and hits
- Written by
- Nobody: the engine never writes it. It works as free memory.
- Cleared
- Nobody: it keeps whatever you store until you change it.
- Range
- −32000 to 32000; it is 0 at birth.
- Mutations
- never picked as a target
By its name, .hitang should give the angle of a collision, but in DarwinBots 2.48.32 no engine system writes or clears it. The name is recognized when the DNA is loaded and points to a memory cell like any other sysvar, and nothing more.
In practice it is free memory with a name: it is 0 from the moment the bot is born, and if you write something to it, it keeps it until you change it, like the unnamed cells (see Free and epigenetic memory). Some Bestiary bots read it, for example EvoZerobot, but what they read is that 0 or whatever they themselves saved.
To know which side a collision came from, the ones that work are .hitup, .hitdn, .hitdx and .hitsx. And if what you are after is an angle, the one of a received shot is in .shang.