Raycast, add options for CollisionsFilterGroup/Mask and skipbackface


For the Raycast ACE, add options for CollisionsFilterGroup/Mask and skipbackface.

A reminder for collision filter group / mask:

  • Filter groups are power of 2: 0,1,2,4,8,16,32, etc.
  • Filter group mask are an OR of the all the filter groups to include (can also just add all the groups, same effect as OR in this case)
  • How to filter collisions using Body.collisionFilterGroup and Body.collisionFilterMask.
  • The filters are applied inside the broadphase. It can be used to allow or disallow collisions between bodies.
  • A collision is allowed if:
    • (bodyA.collisionFilterGroup & bodyB.collisionFilterMask) && (bodyB.collisionFilterGroup & bodyA.collisionFilterMask)
  • These are indeed bitwise operations. Learn more about that here: http://en.wikipedia.org/wiki/Bitwise_operation

Files

mikal_cannon_3d_physics-1.9.0.c3addon 84 kB
Oct 26, 2023
collisionFilter.txt 5.2 kB
Oct 26, 2023

Get Construct 3 3D Physics

Buy Now$10.00 USD or more

Leave a comment

Log in with itch.io to leave a comment.