2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 05:47:42 +00:00

Add triangle flip bit for collision geometry

This commit is contained in:
Jack Andersen
2017-12-08 19:17:51 -10:00
parent 0c1d0b5ce3
commit 5e03278eff
7 changed files with 48 additions and 24 deletions

View File

@@ -12,8 +12,8 @@ CCollisionSurface::CCollisionSurface(const zeus::CVector3f& a, const zeus::CVect
zeus::CVector3f CCollisionSurface::GetNormal() const
{
zeus::CVector3f v1 = xc_b.cross(x0_a);
return zeus::CUnitVector3f({v1.y, v1.z, v1.x}, true);
zeus::CVector3f v1 = (xc_b - x0_a).cross(x18_c - x0_a);
return zeus::CUnitVector3f(v1, true);
}
zeus::CPlane CCollisionSurface::GetPlane() const