(a) It shall be unlawful for any person to use, discharge, or shoot any firearm, handgun, pistol, rifle, shotgun, or an air rifle which projects with a velocity of greater than 500 feet per second, within an area of the unincorporated portions of the county which is designated, pursuant to chapter 58 of this Code, as a residential subdivision or residential development, or within 200 linear feet of a residence located in the unincorporated portion of the county, except in defense of personal property as otherwise authorized by the general law of this state, or after obtaining a written permit from the sheriff, or his designee. (b) This section shall not apply to certified peace officers while in the course of their employment as peace officers. (c) A person committing a violation of this section shall, upon conviction, be punished as provided in section 1-12 of this Code.