How to make a object collide with the camera?

Ok, i am with a VERY VERY BORING problem here. I am making a FPS and obviously my character have a gun. The probelm is that when i reach in walls,trees,etc the gun pass trough them.

It also happens with the camera. When i reload my weapon it pass trought the camera. I already tried to put a camera in the weapon,make a new layer and all,put a collider but it doesn’t work!!

If you didn’t understand, just look at the picture. That’s my problem .-.

Try following this tutorial. Hope it helps.

have you tried rigidbody with a collider?
also try to lower the near value in the camera properties.
the near limit at how close object should be drawn