Browse Source

Fixed assert when a sensor did not do contact point reduction and detected a static body

Jorrit Rouwe 2 years ago
parent
commit
c24af412ff
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Jolt/Physics/PhysicsSystem.cpp

+ 2 - 2
Jolt/Physics/PhysicsSystem.cpp

@@ -1155,8 +1155,8 @@ void PhysicsSystem::ProcessBodyPair(ContactAllocator &ioContactAllocator, const
 				{
 					// One of the following should be true:
 					// - Body 1 is dynamic and body 2 may be dynamic, static or kinematic
-					// - Body 1 is kinematic in which case body 2 should be a sensor
-					JPH_ASSERT(mBody1->IsDynamic() || (mBody1->IsKinematic() && mBody2->IsSensor()));
+					// - Body 1 is not dynamic in which case body 2 should be a sensor
+					JPH_ASSERT(mBody1->IsDynamic() || mBody2->IsSensor());
 					JPH_ASSERT(!ShouldEarlyOut());
 
 					// Test if we want to accept this hit