Why are my guns shooting lower when my character moves forward?

Two of my character’s guns (this is an FPS) shoot straight where it’s aiming when standing still, but shoot lower when walking forward and shoot upward when walking backward. One gun shoots with raycast and the other launches a projectile. There is another gun that shoots with raycast as well, but it doesn’t have this problem. I know it has nothing to do with the script that makes the guns move realistically, as I have tested the game with that script deactivated. Somebody please help.

Perhaps your object that you use for a crosshair is positioned with your camera, which will move when your player is moving. Make sure that nothing is being moved other than the player and the gun animation while you’re moving.