OnTriggerEnter2D Not Working

What I’ve tried so far:

  • Both objects have a collider.
  • The “other” game object is a RigidBody2D and the the parent has “Is Trigger” checked.
  • OnCollisionEnter2D doesn’t work either
  • They are all on the default layer but I checked the Project Settings > Physics 2D anyways.

Code:

    public class PlayManager : MonoBehaviour
    {
    ...
        private void OnTriggerExit2D(Collider2D collision)
        {
            UnityEngine.Debug.Log("Note is exiting the play manager trigger.");
        }
    
        private void OnTriggerEnter2D(Collider2D collision)
        {
            UnityEngine.Debug.Log("Destroying note that was missed.");
            Destroy(collision.gameObject);
        }
    ...

Inspector Screenshots:


Debug lines don’t get called. Please help!

I believe you might have gotten things mixed up. “PlayManager” is a script that reacts to being touched by triggers, you gotta make “trigger objects” collide against your “Play Manager object”. Try making the notes a trigger and see if it helps.