Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
11
Question by LS16BMX · Jun 18, 2012 at 09:40 PM · collidercolliderscylinder

Why no cylinder collider ?

This is causing me no end of problems with my motorbike game, wheel colliders are no good and sphere colliders are just plainly the wrong shape. Please help !

Comment
Add comment · Show 16
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Mizuho · Jun 18, 2012 at 09:42 PM 2
Share

$$anonymous$$esh collider?

avatar image whydoidoit · Jun 18, 2012 at 09:45 PM 0
Share

What @mizuho said - make your own primitive if you need it out of a mesh collider - if a mesh collider on its own isn't enough.

avatar image whydoidoit · Jun 18, 2012 at 10:35 PM 0
Share

It would certainly be faster - I would use the most basic colliders that don't screw up the model. Not sure what needs to be a cylinder on a motor bike - maybe @s$$anonymous$$diworkz could tell us?

avatar image clunk47 · Dec 31, 2012 at 11:27 PM 4
Share

You can have a cylinder collider, technically.. Just add a primmitive cylinder and give it a $$anonymous$$esh Collider. I know, not actually a "cylinder collider", but it works quite well :)

avatar image LS16BMX clunk47 · Jun 25, 2013 at 03:22 PM 0
Share

You can't have mesh colliders colliding with other mesh colliders and thus this won't work. I have scenes where ramps are made from mesh colliders and can't be made any other way.

avatar image Eric5h5 clunk47 · Jun 25, 2013 at 03:31 PM 3
Share

It will work since you can make the cylinder a convex mesh collider. Although this is technically not a cylinder collider, it's a mesh collider that's sort of in the shape of a cylinder. "Sort of" since the surface is a series of flat planes rather than a curved surface, although the built-in cylinder has enough faces that it generally acts as a cylinder when it comes to physics.

avatar image clunk47 clunk47 · Jun 25, 2013 at 04:50 PM 1
Share

Like Eric5h5 says, if it is convex, it CAN collide with other mesh colliders.

Show more comments
avatar image Eric5h5 · Jun 25, 2013 at 03:48 PM 1
Share

@Fattie: nope, video games do not use cubes for wheel colliders, sorry.

Show more comments

3 Replies

· Add your reply
  • Sort: 
avatar image
13
Best Answer

Answer by Eric5h5 · Jun 18, 2012 at 10:36 PM

http://forum.unity3d.com/threads/63967-why-cylinder-collider-doesn-t-exist-!?p=408699&viewfull=1#post408699

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image clunk47 · Jun 25, 2013 at 04:51 PM 0
Share

thx for the reference :)

avatar image spencerfun11 · Jun 03, 2016 at 06:03 PM 0
Share

@ LS16B$$anonymous$$X Try to add mesh collider and set convex to true. That might work.

avatar image
1

Answer by SimonePellegatta · Oct 19, 2020 at 09:32 AM

You can make one by adding two colliders (a Capsule Collider and a Box Collider) to the same object.

You have to overlap them in such a way that their intersection generates a cylinder.

Then:

 ushort triggered = 0;
 
 void OnTriggerEnter() {
     triggered++;
 }
 
 void OnTriggerExit() {
     triggered--;
 
 
 void Update() {
     if(triggered == 2)
     {
         //inside cylinder collider
     }
     else
     {
         //outside cylinder collider
     }
Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by CockCOckIsYes · Jan 12 at 07:34 PM

Add a mesh collider and set the mesh to Cylinder Unfortunately you can't really change the sizes and stuff

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

11 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Avoid character to jump when using capsule collider 0 Answers

Roll a Ball can't pick up game objects in the build? 0 Answers

(Light enabled colliders) given a surface, how to make a collider such that only the portions of the surface in contact with a light source are activated?(Game example included) 0 Answers

Character Controller won't collide with anything 1 Answer

3D game: Pickups don't disappear when player touches them. 4 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges