Ahhh...
You may try this
#macro PointTo(p)
#local Rd = vlength(p);
#if(Rd = 0)
#local Rotx = 0;
#local Roty = 0;
#else
#local Rotx = 180*asin(p.y/Rd)/pi;
#if(p.z = 0)
#local Roty = 0;
#else
#local Roty = 180*atan2(p.x, p.z)/pi;
#end
#end
rotate <Rotx, Roty, 0>
#end
Alberto
Post a reply to this message
|