MouseEvent3D with ObjectContainer3D and Plane

Software: Away3D 3.x

Syrius Amis, Newbie
Posted: 15 October 2011 12:21 PM   Total Posts: 2

Hello!

I have a little bit of a problem with setting up the objects for mouse events.

Scenario (Away3D 3.6.0 + FP 10):

I have a View3D with the default Scene3D and a TargetCamera3D assigned to it.
I created a Plane with a material, added it.
I created several Player class (which is an extended ObjectContainer3D), added a Cylinder into each Player class and added these to the scene.

This works fine however the added MouseEvent3D MOUSE_OVER and MOUSE_OUT don’t work how they supposed to.

It does not fire if I simply move the cursor over a player.
http://images.syriusamis.org/other/Miscellaneous/Away3D/soccer_orig.jpg

It does fire if I move the cursor over a player AND press any key on the keyboard OR click with the mouse.
http://images.syriusamis.org/other/Miscellaneous/Away3D/soccer_with_shift.jpg

It does fire if I flip the plane so I watch the players through it. Note: the plane this way does not have any material (bothFaces off).
http://images.syriusamis.org/other/Miscellaneous/Away3D/soccer_below.jpg

Edited code snippet:
http://pastebin.com/AAzcFE3K

It seems to be something material related but I have no idea what the heck is the problem. Please give me some tips or something. I’m desperate.

~Syrius Amis

   

Syrius Amis, Newbie
Posted: 15 October 2011 02:02 PM   Total Posts: 2   [ # 1 ]

Hello again!

I got a little more details after testing for a while:

I added ROLL_OVER and ROLL_OUT listeners to the Plane and I got the following:

This event dispatches nicely when hovering over and back on the Plane.
If I click a Player, the player’s ROLL_OVER dispatches and the mouse cursor stucks as a hand cursor until I hover the mouse out of the field or hover out the mouse of the player and click/press a key.
Alsi while the cursor is stuck as hand the field’s ROLL_* events aren’t dispatching. It’s a really odd behaviour if you ask me.

Sidenote: I added a MOUSE_MOVE event in the document class and that dispatches fine no matter what happens so it’s something inside the View3D but I still have no idea what it is…

Any help? I’m digging throught the Away3D files to track down how mouseevent’s are handled 3D-wise but someone who actually worked on the code would find the cause of the problem faster.

~Syrius Amis

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X