If they pass right through your mesh, then you have a problem. Try tossing spheres at the mesh so created. The bottom line here is that if your mesh is static (non-moving, non-Rigidbody or kinematic RigidBody), leave convex off and you probably don't have a problem. For complex moving objects that do have concave features, we generally must apply colliders of our own creation if the convex setting produces a collider that isn't of sufficient detail. Real time physics engines of most types can't efficiently handle concave features (cutouts, or like your object, L or U shaped regions). This is related to how the physics engine performs collision testing on moving (Rigidbody) objects (that are not kinematic - Google provides). The convex option does exactly what you're seeing, it ensures the collider is not formed with any concave faces, specifically for use with Rigidbody objects (stuff that moves). It doesn't appear you are using a Rigidbody, so a convex collider isn't required. A non-convex collider is basically the mesh itself. The second image shows a collider in the shape of the mesh. What you're seeing is quite standard and expected. Edit: See commentary below, as now that I understand your objective better, I suggest two convex meshes around the rectangles applied as mesh colliders to the artwork you present.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |