I'm implementing my own 3d vector class.
I have a rotate method like this:
//Rotates the vector around the origin and by the selected angles (in radians)
void CVector3D::Rotate(double rotx, double roty, double rotz)
y = (double)(y*cos(rotx) - z*sin(rotx));
z = (double)(y*sin(rotx) + z*cos(rotx));
x = (double)(x*cos(roty) + z*sin(roty));
z = (double)(- x*sin(roty) + z*cos(roty));
x = (double)(x*cos(rotz) - y*sin(rotz));
y = (double)(x*sin(rotz) + y*cos(rotz));
but it doesn't work...
Anybody can find the error???
And does anybody know if there's a function to rotate a D3DXVECTOR3 ???
[italic]How beautiful, if sorrow had not made Sorrow more beautiful than Beauty itself.[/italic]