Rotate Colliders In Unity

 

Let’s say that I want to add 2 Capsule Colliders to my Palm Tree GameObject like that:

But if I add 2 Capsule Colliders to my Tree GameObject, the best I can do is this:

When you add a Collider component on your GameObject, you will see that there’s NO option to Rotate the Collider any degree you want. You can ONLY Rotate it 90 degrees by y, z, x-axis, change its Position and Scale it.

So to Rotate it how you want, you need to add the Empty GameObject as a Child to your GameObject (for example a Child GameObject to my Palm Tree). To do that RIGHTCLICK on your GameObject(Palm Tree) and select Create Empty.

Now you will see that your GameObject(Palm Tree) has a Child Empty GameObject called GameObject attached to it.

Add a Capsule Collider to the Child GameObject.

Change Capsule Collider Size by changing Radius and Height. To Move or Rotate it, use Transform of the GameObject: This way you can rotate it how you want.

I added another Empty GameObject to my Palm Tree. Here is a finished result with 2 Colliders:

 

Thank you for your time, and I hope you found this quick tutorial helpful! 🙂

Feel free to ask me some questions!

 

If you want to see more stuff I’m working on, follow me on Twitter: @lmhpoly

You can support me by Subscribing to my YouTube channel, it helps me to create more video content for you guys 😉 Video tutorials, Time-lapse videos and more!

You can also follow me on Facebook, Instagram and Google+

Pin It on Pinterest