I'd guess that the aperture lever in the lens has been either broken off, or knocked out of alignment. This would mean that if the lens is a G-type lens, it will always be at minimum aperture and the lack of aperture lever will mean it won't be opened up when it's mounted on the camera. For more hacks check [https://guideusermanual.com/product-name-d3100-manual&po=4310&lang=English|Nikon D3100 Manual.]