- Home /
Unity 5 non-convex mesh collisions
I'm trying to set up some physics-based stuff which worked in an earlier version, but in unity 5 I get the following error:
Non-convex MeshColliders with non-kinematic Rigidbodies are no longer supported in Unity 5.0.
Why? What was the problem with non-convex meshes with rigidbodys that caused this to be removed? If it was a problem, why was it not just fixed?
Is there a way to get unity to ignore this error and get on with it like the previous versions did?
Answer by siaran · Apr 24, 2015 at 06:37 PM
I guess you'll have to use an earlier version if you really want to do this, but... you probably really don't.
In general, you do not want to put non-convex colliders on dynamic objects, that puts a lot of strain on the physics engine. (Calculating collisions on moving non-convex shapes is just really expensive). If you have some dynamic non-convex shape, you should approximate it using primitive colliders. (You should also do this with convex shapes in most cases).
I get that it's expensive but why remove it? Guess I'll have to make do with a work-around.
It's probably related to all the physics updates and optimizations they did for unity 5.
Answer by stanzy · Feb 21, 2017 at 10:36 AM
Use the NonConvexMeshCollider script to solve your problem: http://www.productivity-boost.com/DownloadNonConvexMeshCollider.html I implemented that by myself because I had the same problem.
Well, that's not allowed by the original author as you can read on the archived page.
dont repost the code somewhere else withour my approval, place a link to this page instead.
The author had published the script on the assetstore.
Your answer
Follow this Question
Related Questions
Capsule Collider and Mesh Collider Collision 1 Answer
Stop rigidbody from moving after it falls on another rigidbody 1 Answer
Rigidbody bowls/baskets - is there a better way? 0 Answers
Rigidbody falls through plane 2 Answers
Weird bounce on collision with perfectly aligned (generated) meshes for fast object 3 Answers