mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 22:40:27 +02:00
minor cleanup
This commit is contained in:
parent
8cf7aee009
commit
2162a364a9
1 changed files with 2 additions and 2 deletions
|
@ -421,7 +421,7 @@ const CollisionEvents& PhysicsEngine::getCollisionEvents() {
|
|||
QUuid idB = motionStateB->getObjectID();
|
||||
glm::vec3 position = bulletToGLM(contact.getPositionWorldOnA()) + _originOffset;
|
||||
// NOTE: we're flipping the order of A and B (so that the first objectID is never NULL)
|
||||
// hence we must negate the penetration.
|
||||
// hence we must negate the penetration (because penetration always points from B to A).
|
||||
glm::vec3 penetration = - bulletToGLM(contact.distance * contact.normalWorldOnB);
|
||||
_collisionEvents.push_back(Collision(type, idB, QUuid(), position, penetration, velocityChange));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue