Game Development Community

OnMouseDown picking order

by Eyal Erez · in Torque Game Builder · 12/06/2007 (9:44 am) · 1 replies

Hi,
It seems like when there are two t2dStaticSprite, one infront of the other. the object getting picked(selected by onMouseDown) is the one in the back instead of the front.
Is there a way to control which objects is getting picked by onMouseDown callback?
Thanks,
Eyal.

#1
12/06/2007 (6:04 pm)
I got around it by using sceneWindow2D::onMouseDown instead of t2dStaticSprite callback.
Then I use pickPoint() which does sort by layer.
Cheers,
Eyal.