- Home /
Stop object collision
I've made an invisible wall cube that stops the player passing through an area. Is there any way that I can make a different object able to pass through the the cube while still blocking out the player?
Thanks for any help - Max
@OrangeLightning All links to more info are dead. Searching docs for Collision $$anonymous$$atrix yields 404s.
Answer by FLASHDENMARK · May 20, 2012 at 05:37 PM
Yes, take at look at Unity's Layer-Based Collision Matrix. It sounds a bit complicated, but it is actually really easy and it will fulfill your requirements.
Answer by aldonaletto · May 20, 2012 at 05:41 PM
Use layers: create two new layers - PLayer and Obstacles, for instance - and place the player in PLayer, and the wall in Obstacles. In the Collision Matrix, uncheck collisions in the crossing Default x Obstacles - this will make all objects in Default layer ignore collisions with the anything in Obstacles. Take a look at my answer to this question - it shows a more detailed sequence to achieve this effect.
Your answer
Follow this Question
Related Questions
Invisible walls 2 Answers
Invisible objects renderer disable? How to stop this? 0 Answers
Camera looking through objects when touching 1 Answer
How do I increase speed after collision? 2 Answers
Trying to make an object invisible while hovering.. 2 Answers