CGCorpse_C::GetGroundNormal
function · objectlayer · primitive
- Address
0x5d68c0· 742 bytes, up to0x5d6ba5- Signature
float * __thiscall (CGCorpse_C *this, float *out)- Meaning
- Works out once the mean up-facing triangle normal under the corpse and returns it
- Confidence
- verified, proof one
- Finding
- objectlayer/corpses#the-ground-normal
- Test
objectlayer::dy_corpse_center_inv_difftest,objectlayer::dy_corpse_center_component_difftest,objectlayer::dy_corpse_center_x_difftest
Finding: The ground normal in objectlayer: corpses
Slot 8 (0x5d68c0) gives the corpse's ground normal, worked out once. With the model loaded, a
skeleton that is not submerged first snaps its position to the ground: it traces from half a unit
above the position to ten units below, and a hit becomes the new position. It then queries the
world triangles inside the model's box, scaled and moved to the position and lowered by half its
height, and the normal is the mean of the normals of the triangles that face up.
The derivation is in the doc.
Callers 0
None by a direct call or jump.
Callees 10
- _atexit crt
- SetVector3 spline
- AddVector3InPlace ui
- 0x5132f0 uicamera
- 0x513320 uicamera
- 0x513460 uicamera
- TraceWorldSegment terrain
- QueryWorldTriangles terrain
- CM2Model::IsLoaded models
- CM2Model::GetBoundingBox models
Calls and jumps by a bare address, from tables/calls.tsv.