- Home /
OnTriggerExit2D does not trigger if scaled out of position. Possible solutions?
I have a Trigger object on my Player, which is triggered by grabable tagged objects. My setup works fine, if my trigger physically moves out of position. But when I turn my Player, I scale the Player *-1, and even though the trigger on my player has technically "Exited" the grabable object, it doesn't trigger the exit. I'm guessing due to the instantaneous nature of scaling the Player instantly?
What would be a possible workaround for this? Or could it be a bug?
(Perhaps there a way to check the status of a trigger even while nothing is colliding with it? Or something along those lines?)
Answer by Invertex · Jan 10, 2014 at 08:27 AM
Whelp, I figured out an alright workaround for now, but it's a shame this doesn't work fully. Since it's a 2D game, I simply clear the triggerOccupied and grabableObject variables when a Flip(); is initiated.
I may upload a scene later on just to give proof of the issue.
Your answer
Follow this Question
Related Questions
Any way to prevent sweeptest from colliding their triggers? 1 Answer
Tree Instance scale 1 Answer
OnTriggerEnter called one step too late 0 Answers
Disable Mesh Collider Trigger 1 Answer