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
0
Question by ILEGAL · Jun 09, 2014 at 09:49 AM · boxcollidercapsulecollider

Capsule Collider Going Through Box Collider

Im my game, I have the "main" object with a rigidbody and capsule collider, when force is added, sometimes, this object goes through the box colliders(eqquiped with bouncy physics).

And this can't happen anytime, how can i improve this, so that the object never goes through the box collider, and bounces all the time?

Comment
Add comment · Show 1
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 ILEGAL · Jun 19, 2014 at 12:13 PM 0
Share

anyone? .

2 Replies

· Add your reply
  • Sort: 
avatar image
-1

Answer by applejuices · Jun 11, 2014 at 03:29 PM

ur box collider prob is ugly

Comment
Add comment · Show 1 · 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 ILEGAL · Jun 12, 2014 at 09:31 AM 0
Share

You're lucky I don't see a report button.

avatar image
0

Answer by Lyje · Jun 19, 2014 at 01:44 PM

You might need to set collision type to Continuous or Continuous Dynamic: http://docs.unity3d.com/Manual/class-Rigidbody.html

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 ILEGAL · Jun 19, 2014 at 01:52 PM 0
Share

I used to use Continuous Dynamic until a few days ago, i changed it to Discrete. If continuous dynamic is selected, when my game has too many capsule colliders, they get too slow and stop even without any collision.

With discrete selected I dont have those problems, only when rigidbody gets lots of velocity and goes through the box collider.

Continous Dynamic isn't the solution, I have tried and happened anyway.

Thanks anyway !

avatar image Lyje · Jun 19, 2014 at 02:04 PM 0
Share

Have you tried just Continuous? It might solve both problems. If not, there's a workaround you can do which involves doing a raycast every FixedUpdate to see if an object might have gone through another. You do a raycast from your previous position to your current position; if the raycast hits something, you move the object back to the hit point and let Unity figure out the actual collision properly on the following fixedupdate. There's an implementation of this on the Unify wiki here: http://wiki.unity3d.com/index.php?title=DontGoThroughThings

It might be a little confusing though, and I had to modify it heavily for my own usage.

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

23 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 avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

i wanna prevent my collider from falling down flat when climbing slope 0 Answers

Capsule collider bounces where two ground colliders meet 2 Answers

Set a variable to a collider type. 1 Answer

Colliders not inheriting the Transforms of changed animation states(Run to Crawl) -Unity3D, 0 Answers

How do I know if a cube is lying flat on the ground? (the quickest way) 0 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