This might help. Set your categories outside of the collision function, and then change the categories inside the function. You may not want to add a collision filter to the player though. Just provide a category for the EmptyBody, and then force it to only collide with its own category when it collides with the player.
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Matter dynamic collision error | 2 | 884 | June 22, 2019 | |
| Matterjs can't have a differentiation in my collisions? jsfiddle inside | 2 | 635 | May 22, 2019 | |
| How to make a sprite collide with tiles using matter physics | 2 | 1628 | December 1, 2019 | |
| Matter physics group / categories collide with world not working | 2 | 652 | April 29, 2021 | |
| Matter physics setOnCollideWith() | 3 | 1497 | April 7, 2021 |