- I already had “is trigger” set to true on both “player” and “enemy” colliders
- The “Layer collision matrix” looked ok
and yet, it still didn’t work.
Digging in the doc I noticed that if you only have collider, and no rigid body, on both game objects, it will not trigger OnTriggerEnter2D.
You have to add a RigidBody (2D in our case) to at least one game object in order that it will be triggered at all.
Probably super basic stuff, but sharing anyway in case it helps someone