I'm trying to add a box collider to each piece in my geometry but I'm having trouble fitting the colliders to the pieces.
I'm using a foreach SOP to iterate over each piece and add a collider to each one.
I have tried using the collision_geo group, and a unity_script attribute to add the colliders, and it works well for straight horizontal or vertical pieces. But for diagonal boxes, as shown in the first screenshot, using the collision_geo group causes the colliders to be placed without the correct orientation. And using the unity_script method creates box colliders that fit the pieces' bounding box as shown in the second screenshot.
I have also tried using an attribute wrangle within the for-loop to add a unity_script attribute with parameters to create the colliders via a custom script, but when the asset is built in Unity, the script is called with the exact same values for each piece (which I guess makes sense, since it is a detail attribute, but I'm not sure what the correct way to do this is).
Has anyone found any workaround for this, or know what I'm doing wrong?