theta=pi*cc/2;
d=sqrt(x2*x2+z2*z2);
r=atan2(x2,z2)+theta;
x2=d*sin(r);
z2=d*cos(r); ... and ...theta=pi*cc/2;
ct=cos(theta);
st=sin(theta);
x2=x2*ct-z2*st;
z2=-x2*st-z2*ct; ... do the exact same thing? I thought so, but the second one seems to be acting differently (in other words messing my whole scope up).EDIT: Figured it out. I just needed to make new variables in place of x2 and z2 instead of using them over. Not sure why I would have to do this with the second method and not the first though.
Would a mod be kind enough to lock/delete this thread?