Hi,
I have a problem with the MouseEvent3D on Sprite3D (@Away3D 4.0.9). All MouseEvent3D works badly… more the Sprite3D is far from the camera, more the “hitbox” is small. But with a normal mesh cube it works fine. What’s wrong ?
var spriteSquareMaterial:ColorMaterial = new ColorMaterial(0xFFFF00);
// with Sprite is works bad
var sprite3DSquare:Sprite3D = new Sprite3D(spriteSquareMaterial, 256, 256);
sprite3DSquare.x = 600;
sprite3DSquare.y = 0;
scene.addChild(sprite3DSquare);
// with normal Mesh it works well
var cube:Mesh = new Mesh(new CubeGeometry(), spriteSquareMaterial);
cube.x = 600;
cube.y = 200;
scene.addChild(cube);
// listeners
sprite3DSquare.mouseEnabled = true;
sprite3DSquare.addEventListener(MouseEvent3D.CLICK, pwetClick);
sprite3DSquare.addEventListener(MouseEvent3D.MOUSE_OVER, pwetOver);
sprite3DSquare.addEventListener(MouseEvent3D.MOUSE_OUT, pwetOut);
cube.mouseEnabled = true;
cube.addEventListener(MouseEvent3D.CLICK, pwetClick);
cube.addEventListener(MouseEvent3D.MOUSE_OVER, pwetOver);
cube.addEventListener(MouseEvent3D.MOUSE_OUT, pwetOut);