Tank stabilization

Hi! I using standart mouselook script for my tank turret and gun and its works fine, but now I need vertical and horizontal stabilization. This means that the turret should not repeat the tank Y axis rotation, and rotate that axis only by mouselook script. Gun also should not repeat the rotation of the tank, but only on the X axis and also rotate that axis by mouselook script, plus the have a limit of rotation, taking into account the the tank rotation. Is that possible?

Here some pictures of tank stabilization

alt text

alt text

assuming that you need to stabilize the gun on target. you could set point in space by mouse and make the gun lookat that point.
you can also check the rotation and limit it if it too high. i hope it’s help somehow.