Adobe Air MouseEvent3D mesh not fired?

Software: Away3D 4.x

3dNewb, Sr. Member
Posted: 22 February 2012 05:32 PM   Total Posts: 105

Nothing happens for my mouse events here in Adobe Air, any thoughts?

<fx:Script>
private var 
view:View3D;
   
   public function 
ASTest():void
   {     
    view 
= new View3D();
    
    var 
plane:Mesh = new Mesh(new PlaneGeometry(1000,1000,10,10), new ColorMaterial(0xFF0000,1));
    
    
addEventListener(Event.ENTER_FRAMEenterFrameHandler);
    
    
view.scene.addChild(plane);
    
    
plane.mouseEnabled true;
    
//plane.mouseChildren = true;
    
    
plane.addEventListener(MouseEvent3D.MOUSE_OVER, function($evt:MouseEvent3D):void{
     trace
('mouseOver');
    
});
    
    
plane.addEventListener(MouseEvent3D.MOUSE_DOWN, function($evt:MouseEvent3D):void{
     trace
('mouseDown');
    
});
    
    
view.width 1000;
    
view.height 1000;
    
view.backgroundColor 0;
    
view.camera.position plane.position;
    
view.camera.1000;
    
view.camera.lens.far 50000;
    
view.camera.lookAt(plane.position);
        
    
comp.addChild(view);
}</fx:Script>
 
 <
mx:UIComponent id="comp" width="100%" height="100%" addedToStage="application1_addedToStageHandler(event)"/> 
   

manifreaky, Newbie
Posted: 22 February 2012 05:50 PM   Total Posts: 7   [ # 1 ]

if you are working with the latest version from git, it might be related to the “Drag3D from Alpha to Beta” Issue

edit: the spam blocker didn’t allow me to post a link

 

   

3dNewb, Sr. Member
Posted: 22 February 2012 05:52 PM   Total Posts: 105   [ # 2 ]

I see that thread now, thanks for the heads up. Tipical me: trying out mouseEvents for the first time on the single day they are broken for a few hours. :/

 

   

manifreaky, Newbie
Posted: 22 February 2012 05:54 PM   Total Posts: 7   [ # 3 ]

hehe, you can checkout the previous version, the mouse events should work there

 

   

manifreaky, Newbie
Posted: 22 February 2012 07:01 PM   Total Posts: 7   [ # 4 ]

here is a “hot fix” to enable mouse events in the latest version

 

File Attachments
CHANGED__mouseEvents_hotFix.patch  (File Size: 54KB - Downloads: 0)
   

3dNewb, Sr. Member
Posted: 22 February 2012 07:24 PM   Total Posts: 105   [ # 5 ]

That is very kind of you. Though the forum won’t let me download the attached file, I’ll get it from git.

 

   

manifreaky, Newbie
Posted: 22 February 2012 07:33 PM   Total Posts: 7   [ # 6 ]

neurongate.com/stuff/CHANGED__mouseEvents_hotFix.patch

 

   

3dNewb, Sr. Member
Posted: 22 February 2012 07:34 PM   Total Posts: 105   [ # 7 ]

Awesome!

 

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X