I’m still finding my way around PlayCanvas, so a pointer would be highly appreciated
In the Editor UI I can see a collider class called compound
But I struggle to find the corresponding documentation. My guess is that I can use it to create … well … compounds of various colliders (as children?) and if any of them triggers, so does the compound collider?
I played with it a bit, but couldn’t deduce the logic; hence my question. Any pointer is highly appreciated.
I will have a look at the project. Physics simulation with a compound collider doesn’t work neither in my toy project / playground; could be user-error on my part (likely is).
This opens up an interesting tangent though: How does the entity behave if there is a mix of colliders and triggers? Does it only aggregate colliders with a ridged body for physics and all of them for triggers? I don’t have any specific expectations towards this, but I think I’d really want to know what the engine does in this case to avoid gotchas.
That would be an incorrect setup as only the parent entity should be set as either a rigidBody or just a collider (trigger). The children should only have collider components that define the shape of the compound.
Can you post the project here and someone can take a look?
I do not have any mesh colliders in scene, I use mostly boxes and spheres for simplicity.
I’m using colyseus implementation tho.
Removing the rigidbody got rid of the error.
But now It’s not recognizing the raycast for some unknown reason.
It’s not crashing when I remove the rigidbody, but now it’s not recoginzing the raycast :(.
Same setup 1 parent compound collision component, 1 child box collision component
I can create a test project for this, but can’t at the moment I will get back with the link.
At the moment compound triggers are not supported.
As a workaround, you can make a series of normal primitive kinematic triggers that match the shape you need and add them as children under an entity. You can then move the parent entity, if your trigger needs to move, as it will update the children position as well.