Looks like you are doing an FPS game. If it’s an FPS game it is not ideal to create a collision around the weapon because it will limit the player’s movements. You can see why they don’t do that in the template example.
So, the best way to fix this is to move the arms and the guns away from the viewport. You can follow this tutorial. This is how AAA studios handle the clipping.