Detecting collisions with several colliders

Hi All,

Sorry for my English…

I have a game object with complex geometry that has rigidbody component and several colliders (empty game obects and each empty game object has primitive collider).

In order to detect collision between my main game object and the rest of the world do I have to attach a script (say for example that has only OnTriggerEnter method) to each empty game object that has a collider on it or there is more easy way?

Thank you in advance

1 Answer

1

OnTriggerEnter and OnCollisionEnter are similar but objects with istrigger=true dont block entry also that will never do OnCollisionEnter. What game objects get the script depends on what you want to do with it. I’de help more, But I dont know what it is you want to do.

Thank u for your answer. What I'm trying to ask is if I had game object that has many primitive colliders and I want to check collision do I have to attach a script to each individual collider?