Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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
0
Question by cgartist4jc · Jun 03, 2011 at 05:45 PM · rigidbodycollidercapsulecylinderbarrel

Capsule Collider on Cylinder Doesn't Work

Hey Guys!

I made an oil barrel (cylinder) and put a capsule collider on it. But now, when it falls and hits the ground while tilted, it rolls around the wrong way at both ends (it cuts off the corners), because of the sphere ends of the capsule. And i can't change the rotation constraints, because then it just falls straight down while tilted, which is very unrealistic. And if I use a mesh collider, it will fall through my terrain/plane. Thanks for all the help!

Comment
Add comment
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

2 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by Eric5h5 · Jun 03, 2011 at 05:48 PM

Use a convex mesh collider.

Comment
Add comment · Show 6 · 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 cgartist4jc · Jun 03, 2011 at 05:54 PM 0
Share

ummm, where do I get those. I know, I am a total Newbie!

avatar image Eric5h5 · Jun 03, 2011 at 05:57 PM 0
Share

@cgartist4jc: when you add a mesh collider, look at the checkboxes in the mesh collider component; should be fairly obvious.

avatar image cgartist4jc · Jun 03, 2011 at 06:12 PM 0
Share

Thanks for putting up with the newbie I checked the "convex" box, and it still went through the plane. So I tried assigning a mesh to it, but when I click my mesh, I was rotated, scaled, and transformed wrong. what do I do?!?!

avatar image Eric5h5 · Jun 03, 2011 at 06:31 PM 0
Share

@cgartist4jc: try making it rotated/scaled correctly in your 3D app, or check the mesh import settings.

avatar image njt1982 · Dec 22, 2015 at 12:02 AM 0
Share

This solved it for me. Why do Cylinders default to a capsule collider? Convex mesh is far more accurate...

avatar image Owen-Reynolds njt1982 · Dec 22, 2015 at 12:33 AM 0
Share

Two reasons: 1) You often want something cheap that's close to the right shape. Plenty of people are using it as a fixed-in-place column, for example, where a capsule collider is better (perfectly round.)

2) There's no correct $$anonymous$$esh collider. You rarely want to use the model's mesh for the collider. For example, you might need 24 verts around to make the model look good; but only 10 around for the collider is enough to make it roll nicely.

avatar image
1

Answer by Owen-Reynolds · Jun 04, 2011 at 06:44 AM

A compound collider with a cube on each end doesn't act too badly (add an empty near each end, with only a cube collider.) Make the cubes a tiny but smaller than the capsule radius, so it rolls.

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Mesh vs. Mesh Collider for simple game setup 0 Answers

Capsule Collider not moving with the character 0 Answers

Capsule Collider as a motorcycle simulator? 1 Answer

How to stop an object from moving rigidbody 1 Answer

Camera Rigidbody 1 Answer


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