0

I have a "Door" class object I made, which has an ISceneNode member called "block". Block is the physical manifestation of the door. I need the door to run its "Open" function when it is clicked on.

I am using "getSceneNodeFromScreenCoordinatesBB" and a crosshair so that the user can aim at a door on the other side of the room and open it.

However, getSceneNodeblah returns block. I need to be able to reference the door object that holds block, not block itself. Any suggestions on how I would do that?

Magicaxis
  • 371
  • 7
  • 16
  • Of course I figure it out 10 minutes after asking it lol. Here's my answer:" When the mouse is clicked, get the positions of all the objects in your field of vision, and compare them to the SceneNode you are looking at. The one that matches is your object. – Magicaxis May 18 '12 at 13:27
  • Good job for finding the solution alone. Can you rewrite your comment as an answer and accept it, to keep the place tidy? – Simon May 25 '12 at 02:37

1 Answers1

0

Of course I figure it out 10 minutes after asking it lol. Here's my answer:" When the mouse is clicked, get the positions of all the objects in your field of vision, and compare them to the SceneNode you are looking at. The one that matches is your object.

Magicaxis
  • 371
  • 7
  • 16