It is only in movies that we see guns firing lasers, sonic blasts, rays, and etc. In real life and for the most part, guns just fire regular bullets. However it looks like the US Army is trying to give its soldiers an edge over the enemy as it appears that they are testing ray gun attachments for their soldiers’ rifles.
Dubbed the Burke Pulser attachment, basically these ray gun attachments will use a piezoelectric generator and two antennas to help generate bursts of electricity, and all of this will fit nicely onto the end of the Army’s M4 carbine rifle the same way one would attach a standard-issue flash suppressor, meaning that there won’t be a need to modify existing guns.
That being said the attachment isn’t so much going to be used against human beings, but will target roadside bombs and IEDs where the electric pulse from the attachment will be used to fry the circuitry in these bombs, ultimately defusing them in the process. In a way it is similar to the HEL-MD lasers which are used to neutralize incoming aerial threats, except these guns will be wielded by soldiers on the ground.
At the moment the gun attachment is said to be in its early stages of development, but it has been estimated that it would cost around $1,000 to produce each device.