Face.offset method missing?

Software: Away3D 3.x

djumeau, Newbie
Posted: 31 October 2012 03:25 PM   Total Posts: 1

I am going through “Essential 3D for Flash” and on the chapter to create custom meshes. As I am coding, I discovered that “offset” method is missing from the “Face” class. (Probably this was deliberate.) Does anyone know of a quick way to implement this in the code? Sample Code below. (Issue commented out.)

var mesh:Mesh = new Mesh();
  mesh.bothsides = true;
 
  var material:WireColorMaterial = new WireColorMaterial(0xFF0000);
  material.wireColor = 0x000000;
  material.thickness = 2;
  mesh.material = material;
 
  _view.scene.addChild(mesh);
 
  //Triangle
  var face0:Face = new Face();
  face0.moveTo(-50, -50, 0);
  face0.lineTo(50, 50, 0);
  face0.lineTo(-50, 50, 0);
  face0.lineTo(-50, -50, 0);
  //face0.offset(-300, 0, 0);
 
  mesh.addFace(face0);

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X