The ray gun has long been a staple of science fiction, but you still don’t see too many of them around. The main reason seems to be that they would require a major power source, hence making handheld energy weapons largely impractical. So we’re stuck with boring old bullets for when we want to kill someone quickly. The Wikipedia entry cites the heat rays used by the Martians in War of the Worlds as one of the earliest examples.
Soon, people had imagined rays that could stun, freeze, shrink, weld, disintegrate…you name it, really.
Also, ray guns in early twentieth-century fiction tended to be really noisy.
Obviously real technology can’t keep up with human imagination, but there have certainly been many attempts to make directed-energy weapons a reality. One of the first to experiment with them was Nikola Tesla, whose proposed teleforce weapon would use high voltage to accelerate a stream of tungsten pellets. In his later life, he was known to have claimed that he’d actually invented such a thing, but it’s obviously never been found. The early 1950s saw the invention of the maser, or Microwave Amplification from Stimulated Emission of Radiation. It was never used as a weapon, but the principle of using stimulated emission to produce coherent waves (whatever that means) could have been applied to such devices. Indeed, the phasers on Star Trek, which could be set to stun, kill, or disintegrate, were apparently originally considered photon masers.
In 1960, Theodore Maiman successfully operated the first optical maser, known by Gordon Gould’s term “laser” (Light Amplification by Stimulated Emission of Radiation). Lasers are used for many purposes today, including eye surgery, barcode scanning, playing CDs and DVDs, and of course projecting images at planetariums to accompany the music of Pink Floyd. An electrolaser can use a laser-induced plasma channel to direct electricity at its target, so laser weapons are indeed real, but not practical as handheld devices. Of course, the laser took the sci-fi world by storm, and a lot of ray guns became specifically laser guns. Star Wars uses laser blasters, although they’re not portrayed very realistically. They shoot laser bolts (so they’re technically not ray guns from a mathematical perspective) that can be seen and dodged. The same universe has lightsabers, which are basically lasers made to function like swords.
Needless to say, it’s unlikely that a functioning lightsaber will ever be made, although I’m sure it would be the ultimate collector’s item if it ever could. We wouldn’t have to worry about its actually being used, because a collector wouldn’t dare take it out of its original packaging. Anyway, getting back to inventions that rhyme with “blazer,” there’s always the Taser, an actual energy weapon that can stun people.
Originally created in 1974, the earliest Tasers used gunpowder, but innovations in the nineties would make this unnecessary. The name is an acronym for “Thomas A. Swift’s Electric Rifle,” after a similar gun used in one of the Tom Swift books.
The middle initial was added to make the acronym work, and probably to make a connection to masers and lasers; Swift’s middle initial was apparently never revealed in the books. Tasers are quite ubiquitous in the modern age, with police frequently using them against any suspect, including old blind ladies who don’t clean their yards and kids fighting with pencils. Even Martian invaders probably think that’s pretty low.