I just have a little issue with mesh collider on the ring and wanted / needed some suggestion as how to go about it.
Since mesh colliders will not collide with each other, what’s the best way or better way of adding a collider to this ring. What I wanted is when a ring(s) goes thru the pole it will stack on top of each other.
I’m thinking of adding a box collider (thru scripting) after it hits the base(floor). My concern is if a ring goes thru the pole hits the floor and scores then a box collider will be added to it, the triggers surrounding the pole will be activated again thus giving another score.
Also see my attached image of another issue I have when a ring will just hang on the edge of the pole. 2 mesh colliders can’t collide.
right now my solution is just to destroy the ring in a few seconds after it hits anything. But I rather see the rings in there.
I think I understand what you’re trying to do. I’ve been experimenting with more complex colliders as well. One thought for your situation is to divide the rings into segments and make each segment a separate object. Then parent the segment/objects together and give each segment a separate box collider. Four or five segments should be enough. One thing I learned is that when you create the box colliders, you have to be careful that they aren’t touching each other. I usually add a bit of space between them (but smaller than the post’s diameter) just to make sure they aren’t touching.
If you’d rather not divide the ring into segments (which might not look great and will increase the object count), you can have a bunch of boxes arranged into a ring shape, and parent those to the ring (which itself would have no collider). Then turn the renderer off for the boxes. And yeah, make sure they’re not touching.
You can have multiple colliders without splitting up the mesh. Try this:
Make a new empty game object. Attach it as a child to your ring mesh object. Add a capsule collider to the empty game object. Use the Collider controls in the inspector to size line up the collider with one spot of the ring. Now repeat adding game objects and attaching capsule colliders, moving them in different places until you have enough coverage around the whole ring. Then make sure that the ring mesh object is the only one with a rigidbody.
I also need to avoid the object count as the ring itself has 1600 tris.
Trying a sphere, box and a capsule colliders. I think the box is a lot easier to resize and rotate. I’m getting lazy over here :). Would be a lot easier if there’s a ring collider option.
Thanks guys for the suggestions, appreciate it very much.
Ray
The reason I suggested making boxes (or whatever you want to use) and then turning off the renderers for them, is because that makes it easier to set up and fiddle with the objects, rather than making empties and adding colliders to them. Once the renderers are turned off, they don’t count as objects any more than empties with colliders do. The end result is the same, but I find that dealing with visible objects is a lot easier for setting up complex colliders. For example, you can put together 1/4 of the ring shape, group those objects together, and then duplicate it three times and arrange the 4 elements into 1 ring shape. Then parent those to the ring and turn the renderers off. Would save some effort…
I got it working really nice, But I’m still going to end up destroying the rings after a few seconds as my FPS just drops by 1/2, runs crappy on a Macbook.
Tried running it as it was before and my FPS was still dropping like a rock.
I can’t reduce the poly count on the rings as it will not look round. Maybe will remove some pins or reduce their count instead.
That was fun though, learned something really neat.