Report all triggers to the user
| 1743 | |
| 1744 | // Report all triggers to the user |
| 1745 | void CollisionDetectionSystem::reportTriggers(EventListener& eventListener, Array<ContactPair>* contactPairs, Array<ContactPair>& lostContactPairs) { |
| 1746 | |
| 1747 | RP3D_PROFILE("CollisionDetectionSystem::reportTriggers()", mProfiler); |
| 1748 | |
| 1749 | // If there are contacts |
| 1750 | if (contactPairs->size() + lostContactPairs.size() > 0) { |
| 1751 | |
| 1752 | OverlapCallback::CallbackData callbackData(*contactPairs, lostContactPairs, true, *mWorld); |
| 1753 | |
| 1754 | // Call the callback method to report the overlapping shapes |
| 1755 | eventListener.onTrigger(callbackData); |
| 1756 | } |
| 1757 | } |
| 1758 | |
| 1759 | // Report all contacts for debug rendering |
| 1760 | void CollisionDetectionSystem::reportDebugRenderingContacts(Array<ContactPair>* contactPairs, Array<ContactManifold>* manifolds, Array<ContactPoint>* contactPoints, Array<ContactPair>& lostContactPairs) { |