benilla-re systems structs docs

s_gatherEpsilon

global · terrain

Address
0x8101b8 · 4 bytes, up to 0x8101bb
Type
float
Meaning
Holds 0.019444443 (0x3c9f49f4), the margin a facet gather grows its box by
Confidence
verified, proof one
Finding
terrain/collide#chunk-facets

Finding: Chunk facets in terrain: collide

0x6aadc0 gathers a chunk's facets: four triangles per cell of the rectangle clamped to the chunk, skipping holes, from its inner vertex C and corners V, V+1, V+17 and V+18 as (V+17, C, V), (C, V+1, V), (C, V+17, V+18) and (C, V+18, V+1). A triangle is kept unless one face of the box, grown by 0.019444443 and taken relative to the chunk, has all three vertices outside. The vertices are stored as chunk vertex plus position. It also adds an impassable chunk's walls, the liquid slots' facets and the doodads' and entities' by the mask.

The derivation is in the doc.