Hey, I wanted to see if someone could help me with this,
My issue is related to this question in StackOverflow
Basically, in the engine, OnPointerExit
gets called when the mouse leaves the object you selected, hover etc…
However in android/IOS OnPointerExit
gets called alongside OnPointerUp
And usually this is not a big deal, BUT, I have a button that the user can keep pressing down to do some functionality and if the user lifts their finger or leaves the button I stop it, in other words what I’m doing is:
OnPointerDown
I start the coroutine
in On OnPointerUp
and in OnPointerExit
I stop the coroutine
This works perfectly in editor, but in touch, I can press down the button, start the coroutine, drag my finger outside the button and the coroutine keeps running
In StackOverflow, Odaimoko recommends to check if PointerEventData.pointerCurrentRaycast.gameObject
is the same as PointerEventData.pointerPressRaycast.gameObject
I tried this, I but it as a condition inside my coroutine , but not matter what I try, I’m unable to replicate the OnPointerExit behavior on the android build
I’ve been stuck with this a couple of days, If anyone has any advice or workarounds I would really appreciate it