   Complex Rotation problem
  I've been having trouble with using complex numbers and rotations (2D). I have a sprite that I need to rotate with x and y coords but since i'm using complex numbers which takes up only 1 parameter it does not draw on the Y plane. If I use the equation for both x, y params it does not work either.. Here is my equationfloat D[2];D[0] = A[0] - B[0];D[1] = A[1] - B[1];float Rot;Rot = (D[0] + D[1]) * (cos(Q) - sin(Q));draw_gun_sprite(Rot, 0/*y coord*/);Sorry if I'm being vague or I'm not explaining something correctly.Thanks,N   
  Complex rotation is the same as multiplying with a rotation matrix.C=X+iY // Vector to rotateR=cos(T)+isin(T) // Vector to rotate byC*R = X*cos(T)-Y*sin(T) + i(X*sin(T)+Y*cos(T))This is the rotation matrix:cos(T) -sin(T)sin(T) cos(T)Same as here: http://en.wikipedia.org/wiki/Transformation_matrix   