forgot to flip a normal
This commit is contained in:
parent
987a1fa515
commit
6451ca5e95
|
@ -66,7 +66,7 @@
|
||||||
NumberOfChildren: 0
|
NumberOfChildren: 0
|
||||||
Components:
|
Components:
|
||||||
Transform Component:
|
Transform Component:
|
||||||
Translate: {x: -2.24715948, y: 6.47200441, z: 0}
|
Translate: {x: -1.98839664, y: 7.7662077, z: 0}
|
||||||
Rotate: {x: -0, y: 0, z: -0}
|
Rotate: {x: -0, y: 0, z: -0}
|
||||||
Scale: {x: 1, y: 1, z: 1}
|
Scale: {x: 1, y: 1, z: 1}
|
||||||
IsActive: true
|
IsActive: true
|
||||||
|
|
|
@ -102,7 +102,7 @@ namespace SHADE
|
||||||
// Check if center is inside polyhedron (below the face)
|
// Check if center is inside polyhedron (below the face)
|
||||||
if (bestDistance < SHMath::EPSILON)
|
if (bestDistance < SHMath::EPSILON)
|
||||||
{
|
{
|
||||||
manifold.normal = CONVEX.GetNormal(closestFaceIndex);
|
manifold.normal = -CONVEX.GetNormal(closestFaceIndex);
|
||||||
|
|
||||||
SHContact newContact;
|
SHContact newContact;
|
||||||
newContact.penetration = PENETRATION;
|
newContact.penetration = PENETRATION;
|
||||||
|
@ -179,7 +179,7 @@ namespace SHADE
|
||||||
if (projection >= 0.0f)
|
if (projection >= 0.0f)
|
||||||
{
|
{
|
||||||
// Sphere Within region
|
// Sphere Within region
|
||||||
manifold.normal = CP_TO_CENTER;
|
manifold.normal = -CP_TO_CENTER;
|
||||||
|
|
||||||
SHContact newContact;
|
SHContact newContact;
|
||||||
newContact.penetration = RADIUS - projection;
|
newContact.penetration = RADIUS - projection;
|
||||||
|
|
Loading…
Reference in New Issue