Object2VR:Test hit of hotspot with another object (or point)
Posted: Thu Nov 21, 2013 5:37 pm
Hey guys,
I am loading an object2vr swf into another swf. Once it is loaded, I am creating a custom pointer which should serve as an indicator for the user as it will be probably controlled by Leap Motion or something similar. So no mouse. The problem is that it is impossible to click the hotspot like this, because I do not know when the user is over a hotspot. While you added an on click/mouse over/ etc. listeners to the hotspots (which work alright, of course, if you have a mouse), I would need to retrieve the hotspot "clickable area" and hittest it with my custom pointer sprite. Once there is a hit and the user makes a "tap", I can call some function.
So the question is: How can I retrieve the hotspot sprite/displayobject? What is its path? What object is it? I really need that reference...
Thanks a lot!
EDIT: Changed the title as this thread was moved to the AS forum.
I am loading an object2vr swf into another swf. Once it is loaded, I am creating a custom pointer which should serve as an indicator for the user as it will be probably controlled by Leap Motion or something similar. So no mouse. The problem is that it is impossible to click the hotspot like this, because I do not know when the user is over a hotspot. While you added an on click/mouse over/ etc. listeners to the hotspots (which work alright, of course, if you have a mouse), I would need to retrieve the hotspot "clickable area" and hittest it with my custom pointer sprite. Once there is a hit and the user makes a "tap", I can call some function.
So the question is: How can I retrieve the hotspot sprite/displayobject? What is its path? What object is it? I really need that reference...
Thanks a lot!
EDIT: Changed the title as this thread was moved to the AS forum.