- Home /
OnTriggerEnter2D not being called?
Hey!
I'm trying to start with Unity but I'm having some problems.
I'm trying to recognize when a rigidbody2D enters in an area. For this, I created a gameObject and added a 2D Circle or Box Collider (checked "is Trigger") and attached a script with OnTriggerEnter2D. This Object is the area. The OnTriggerEnter2D method is never being called.
I tried adding a script on the moving object with the OnTriggerEnte2D, but again it is never being called.
What am I doing wrong?
is your moving object is collider2D too? cause collider is not compatible in physics2D.
I'm having this same problem and am desperate for help!
I have the exact same problem :o I tried everything but it never worked :(
Answer by ray2yar · Dec 27, 2018 at 02:56 AM
Your moving objects need a rigidbody2d on them for the trigger to function.