MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / GetCenterPoint

Function GetCenterPoint

Descent3/NewPyroGauges.cpp:426–434  ·  view source on GitHub ↗

This function will return the center point of a flat face in global screen coordinates

Source from the content-addressed store, hash-verified

424
425// This function will return the center point of a flat face in global screen coordinates
426void GetCenterPoint(int *x, int *y, vector *wpos) {
427 g3Point pt;
428
429 g3_RotatePoint(&pt, wpos);
430 g3_ProjectPoint(&pt);
431
432 *x = (int)pt.p3_sx;
433 *y = (int)pt.p3_sy;
434}

Callers

nothing calls this directly

Calls 2

g3_RotatePointFunction · 0.85
g3_ProjectPointFunction · 0.85

Tested by

no test coverage detected