- Home /
Question by
schizophrenicGhost · Jul 17, 2015 at 04:00 AM ·
2dcollisiontrigger
OnTriggerEnter2D using child's Trigger Box
In one of my sprites there is a script that calls OnTriggerEnter2D, but instead of using the trigger box that is in the parent class, it is using the trigger box that is placed in the child object. I have tested this by changing the sizes of the trigger boxes and the method only seems to react to the child's trigger. Is there any way to change the specific trigger that is used for OnTriggerEnter2D?
Comment
Answer by Oribow · Jul 17, 2015 at 01:12 PM
No, there is no way. OnTriggerEnter2D can only be called from the GameObject the script is attached to.