Nevermind! I found the solution myself after one more try. I had tried for a long time using
var m:Matrix3D = this.sceneTransform; var v:Vector3D = new Vector3D(-1,0,0); // because the object is "facing" to the left; v = m.transformVector(v); now it seems like the translation screwed up and I should use m.deltaTransformVector(v) instead. Works like a charm! Now of course if anyone else has a better (read faster and more optimized) way to solve this. Please let me know about it. /Andreas On Jun 12, 10:21 pm, Andreas Jirenius <[email protected]> wrote: > Ok, I have never studied math above the "normal" level and actually > never studied matrices in any way so please help me out here :) > > I got an ObjectContainer3D that is rotated in different axis. Also I > got a smaller ObjectContainer3D as a child inside this first one. The > child is ALSO rotated in different ways. > Is there any simple solution the get a global(!) Vector pointing in > the direction the smaller object is "looking at" (preferrable). Or > maybe get the global rotation of the smaller object (x,y and z). > > Grateful for any help!
