Hola gente, estoy haciendo un menú orbital y estoy teniendo problemas que un tema de profundidad.
El codigo que use lo saque del tutorial
Objetos 3D animados por Actionscript 3 usando drawTriangles
http://www.cristalab.com/tutoriales/objetos-3d-animados-por-actionscript-3-usando-drawtriangles-c264l/

Y arme el siguiente codigo:

Código ActionScript :


var cubo:Sprite = new Sprite();
cubo.y=270/2;
cubo.x=360/2;
cubo.alpha=0.5;
cubo.visible=false;
//trace(_root.getChildIndex(cubo));
addChild(cubo);
// 

var boton:MovieClip;
var matrix3D:Matrix3D = new Matrix3D();
var points:Vector.<Number>=new Vector.<Number>  ;
var vertices:Vector.<Number>=new Vector.<Number>  ;
var aristas:Vector.<int>=new Vector.<int>  ;
var UVData:Vector.<Number>=new Vector.<Number>  ;

var largo:int=100;
var rad:Number=72*Math.PI/180;
var rad2:Number = (72/2)*Math.PI/180;
var rad3:Number = (30)*Math.PI/180;
// 
points = Vector.<Number>([
  0, largo, 0,
  Math.sin(rad)*largo,Math.cos(rad)*largo,0,
  Math.sin(rad2)*largo,-(Math.cos(rad2)*largo),0,
  -(Math.sin(rad2)*largo),-(Math.cos(rad2)*largo),0,
  -(Math.sin(rad)*largo),Math.cos(rad)*largo,0,
  
  0,Math.sin(rad3)*largo,Math.cos(rad3)*largo,
  0,-(Math.sin(rad3)*largo),Math.cos(rad3)*largo,
  
  Math.sin(rad3)*largo,0,-(Math.cos(rad3)*largo),
  -(Math.sin(rad3)*largo),0,-(Math.cos(rad3)*largo)
  
]);
// 
aristas = Vector.<int>([
 0,1,5, 1,6,5, 1,2,6, 2,3,6, 3,4,6, 4,5,6, 0,5,4,
 
 8,7,0, 7,1,0, 7,2,1, 7,3,2, 3,7,8, 8,4,3, 0,4,8
]);
// 
addEventListener(Event.ENTER_FRAME, eventHandler);
// 
function eventHandler(event:Event):void {
   switch (event.type) {
      case Event.ENTER_FRAME :
         matrix3D.appendRotation((cubo.y + (mouseY-cubo.y*2))/20, Vector3D.X_AXIS);
         matrix3D.appendRotation((cubo.x - mouseX)/20, Vector3D.Y_AXIS);
         Utils3D.projectVectors(matrix3D, points, vertices, UVData);
         //
         cubo.graphics.clear();
         cubo.graphics.beginFill(0xCA0B45,1);
         cubo.graphics.lineStyle(.1,0xA30736,1);
         cubo.graphics.drawTriangles(vertices, aristas, null, TriangleCulling.POSITIVE);
         //cubo.graphics
         cubo.graphics.endFill();
   }
   //trace(vertices+"\n\n");
   for (var i:Number = 0; i<9; i++) {
      //trace(this['t'+i+'_mc']);
      boton = this['t'+(i+1)+'_mc'];
      boton.x=vertices[i*2]+cubo.x;
      boton.y = vertices[(i*2)+1] + cubo.y;


      boton.posX=vertices[i*2]+cubo.x;
      boton.posY = vertices[(i*2)+1] + cubo.y;
   }

}






A los botones que orbitan les asigno la posición que me da el array "vertices" para posicionarlos en el flash, pero también necesitaría la posición Z de cada punto en ese instante para obtener la profundidad y así a cada boton cambiarles la escala dependiendo de la profundidad.

Desde ya muchísimas gracias.