MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / GetSurfaceNormal

Method GetSurfaceNormal

TombEngine/Game/collision/floordata.cpp:70–78  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

68}
69
70Vector3 FloorInfo::GetSurfaceNormal(int triID, bool isFloor) const
71{
72 // Get triangle.
73 const auto& tris = isFloor ? FloorSurface.Triangles : CeilingSurface.Triangles;
74 const auto& tri = tris[triID];
75
76 // Return plane normal.
77 return tri.Plane.Normal();
78}
79
80Vector3 FloorInfo::GetSurfaceNormal(int x, int z, bool isFloor) const
81{

Callers 3

GetFloorNormalMethod · 0.80
GetCeilingNormalMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected