Is there a 3d version of collision2d.otherCollider?

I’m making a car game and I want to make it so that parts of the car will break if I hit to hard. the car is a parent of multiple colliders. I want to find out which one is colliding.

I’m not certain if this will help you, but it seems that you can access info on an “otherCollider” via the ContactPoint.

Without testing it, I’d suggest starting with something like this:

theIncomingCollision.GetContact(0).otherCollider

_

Here’s where I checked to come up with that.

  1. Unity - Scripting API: Collider.OnCollisionEnter(Collision)

  2. Unity - Scripting API: Collision

  3. Unity - Scripting API: Collision.GetContact

  4. Unity - Scripting API: ContactPoint

  5. Unity - Scripting API: ContactPoint.otherCollider

Depending on how spread out the collision is, you may have to iterate over a series of contact points via GetContacts to find the one you need.

I hope this can help you.