The .lookAt() function and .rotateTo()

Software: Away3D 4.x

synkarius, Member
Posted: 23 December 2012 08:06 AM   Total Posts: 64

Hi all. I have a question. Why does this:

var ob:Mesh = new Mesh(myGeometrymyMaterial);
ob.lookAt(myPosition);
var 
storedRotations:Vector<Number> = Vector([]);
storedRotations.push(myPosition.xmyPosition.ymyPosition.z);
ob.rotateTo(new Vector3D());
ob.rotateTo(new Vector3D(storedRotations[0]storedRotations[1]storedRotations[2]); 

not do the same thing as this?:

var ob:Mesh = new Mesh(myGeometrymyMaterial);
ob.lookAt(myPosition); 
   

synkarius, Member
Posted: 23 December 2012 05:35 PM   Total Posts: 64   [ # 1 ]

Nevermind. This works. I made a silly mistake elsewhere.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X