Concave Trigger on Mesh

In my game, I have set up splines that the player can grind along as rails. I have created a script that takes the data from each of the splines and draws a mesh collider based on their shape that acts as a trigger to mount the rail.

This is the best option for me, as it allows the players to create their own rails and saves me and my team time placing the rails without spending ages placing primitive mesh colliders along the spline.

The only problem I have with this system is that Unity doesn’t allow me to have concave colliders as triggers, which means that I can only have convex colliders encompassing all of my rails. This is ok for things like this:

But if I want complex and curvy rail systems …it comes out like this:

Obviously, there is no way that I can use this in my game.

Is there any way that I can get a concave mesh to act as a trigger -that doesn’t involve me spending money on an asset, or using an older version of Unity?

If not, are there any workarounds?

Thanks in advance.

I had a similair problem in a rail design game we’re developing. One of the features is that it should detect rail assets clashing a buffer zone of the centreline of the rail track. I created a script that extrudes a profile along the track and creates a single mesh for the buffer. I couldn’t use this mesh however because of the same reasons you mention. Unity doesn’t support a non convex mesh to act as a trigger. Quite a limitation if you ask me.

I didn’t see any other option then just rewrite my mesh creation script to create a mesh foreach section of the track. Perhaps you can do the same. I still prefer the buffer to be a single mesh however. Makes everthing much more simple.