@WMC: I'd say only my change... explanation below.
@Nuke: Surely I could be wrong, but as I am viewing it, the "desired_angles.X = XXX" calculates from the vector to the target what angles the turret should try to face - they don't do something to the turret itself. Then, the turrets rotation speed is read ("float step_size = turret->turret_turning_rate * flFrametime;") and used in the following commands which then actually move the turret parts around to point to the previously calculated target angles.
I see, I didn't realize that myself in the first post I made in this thread...

Still, if the lines you're proposing were changed, that might quite possibly result in the turret trying to face 90 degree AWAY from its target (or something even more crazy

), still only rotating around the old axes...
My assumptions might be wrong, but they seem rather plausible to me. As I said, I didn't realize it myself at the start, but now I think that first statement of mine was way too rushed... :/ Hope the new one's better though...

[edit1] Oh, and the "(float)acos(of_dst.xyz.z)"-line gives me a major headache - shouldn't an acos take TWO lengths as argument???
