Using standard asses ‘FPS Contoller’ where the camera is a component not its own object.The gun attached to the controller follows rotation in y axis (left and right) but the gun does not follow pitch.(x axis)
Ive tried applying
void Update ()
{
gameObject.transform.localRotation = cam.localRotation;
}
to the gun where cam is a reference to the camera component but no luck!!! Any help would be greatly appreciated!!