Introduction: Invention
Some authors are of the opinion that the invention of gunpowder marks the end of fantasy. To some extent, that's true, as the introduction of powder weapons into Europe starting in the 14th century did change the battlefield. That change was one of the many that brought about the end of an era, as medieval gave way to Renaissance, but this was a long, complex process. It didn't happen overnight.
Personally, I believe there is room for coexistence. Guns can live alongside fantasy elements in a story, and they can do so without one crowding out the other. In recent years, we've witnessed the growth of subgenres oriented around more modern weaponry, such as "riflepunk" and flintlock fantasy. Brian McClellan, for instance, has made a name for himself with the Powder Mage and Gods of Blood and Powder series. So it's not impossible. It just requires a little more care and thought, but isn't that true with any part of writing?
First, let's think about gunpowder itself. As most of you know, traditional black powder is composed of three primary parts: charcoal, sulfur, and a nitrate. The charcoal is a source of carbon, but with impurities that lower the ignition temperature and thus make for a better explosion. Sulfur serves as a secondary fuel source and igniter. These two are fairly simple, and they're chemicals that have been known since ancient times.
The canonical third part is potassium nitrate, better known as saltpeter. Any kind of nitrate tends to get involved in some very energetic chemical reactions, but potassium nitrate has a lot of natural sources...once you know what to look for. Bat guano provided a source in ages past, while some places instead made use of human guano, i.e., feces and urine. Whatever way you get it, whether dangerous or disgusting, you end up with a really good oxidizer.
Even if you don't have a ready source of saltpeter (or the stomach for manufacturing it), you can get by with sodium nitrate instead. It's not as good for bullets, but it works just fine for explosions—"blasting" powder is often sodium nitrate-based gunpowder. Most of it was initially mined, as the Atacama Desert is full of natural deposits. In modern times, synthetic sodium nitrate is produced via the Haber-Bosch process, a industrial-scale method for ammonia production that has a whole host of peaceful uses, but started out as a way for Germany to make gunpowder when their imports were cut off during WWI.
Whichever chemical you choose, your nitrate mixes with the charcoal and sulfur, but I'm obviously not going to detail the method here. The end result is gunpowder of a kind that wouldn't be out of place on any battlefield from Renaissance Italy to the Western Front. Over half a millennium, but the story of this incredible chemical dates back even farther.
Saltpeter was described in China as early as the 2nd century, while the formula for gunpowder is as old as the 11th. It may have been used for "playful" purposes such as firecrackers first; certainly the attempts at finding medicinal uses came quickly. In warfare, we know it to be present during the Song dynasty, contemporaneous with the High Middle Ages in Europe. Bombs started the trend, followed soon after by cannons.
From there, it spread like wildfire. The Mongols had powder weapons in the mid-13th century, and they turned them against Europeans. Roger Bacon, because he didn't do enough already, referenced it in his writings. Alfonso X, king of Castile before it was part of Spain, had to face it in the Reconquista. The famed Battle of Crécy, in 1346, marked the first real use of a "Western" cannon.
Transition period
Read that last sentence again. Crécy, 1346. You know, the one with the English longbows. Probably the battle that was supposed to define the High Middle Ages as it's portrayed in the majority of fantasy literature. The model for combined arms, the gallantry of knights on the battlefield, and so on. Even it had gunpowder weapons. Were we duped all along?
Not really. The early cannon served as shock value as much as an actual weapon. They were experimental, much like tanks in WWI or jets in WWII. The Black Prince would have been insane to rely on them, because they just weren't that reliable yet. Few people had the knowledge to make the things, first of all. The materials they required, such as the aforementioned saltpeter, were relatively expensive or otherwise hard to come by. Tolerances were strict, further adding to cost; you don't want to be the one whose shiny new cannon blows up in the prince's face the first time you fire it.
Thus, the 14th century marks a transition period between the medieval world of the longbow, trebuchet, and knight on one hand, and the Renaissance era of musket and cannon on the other. It's true that, after Crécy, guns started popping up everywhere in short order. Writers from 1350 called them common sights on the battlefield. The arquebus, a predecessor to the musket, made its debut around that time, too; by 1400, it was the hot commodity in weaponry from Madrid to Rome and everywhere in between.
Looked at like that, we might wonder if fantasy's favorite age wasn't a lot shorter than we were led to believe. And we'd be on the right track. Those of you who know your history also know another pivotal, world-changing event that happened in the middle of the 14th century: the Black Death. The height of the plague coincided with the introduction of gunpowder—as both were imported from the invading Mongols, this isn't all that surprising. Not only did the Black Death wipe out a significant fraction of the population, far more than any modern pandemic, it created massive upheaval in the social sphere.
Powder, then, contributed to the fall of fantasy-style warfare, but the culture that surrounded it—that created it—died, like so much else, to the plague.
Death or rebirth?
That doesn't mean the introduction of guns marks the end of fantasy. Not at all. Though the battlefield was shifting, the old guard held on for a while longer. Knights looked down on the use of guns, seeing them as uncouth. Interestingly enough, that was as true in Europe as it was on the other side of the world: Japanese samurai didn't much like a weapon that so went against the warrior code, either.
Tactics had to change, except that they were already changing in the right direction, focusing on the interplay of infantry, cavalry, and artillery. The cannon, in this view, could be seen as just a much more powerful artillery weapon. Handguns, however, meant that the age of the shield and square was at its end. Both of these were replaced by the infantry line, which Americans will know from the Revolution all the way to Gettysburg. But early examples of these weapons had a major flaw: time to reload. Much like crossbows, a musket or arquebus needed some time to get ready again after a shot, and that gave a wise commander an opening.
So, let's assume your fantasy army has guns of the sort that would be found in, say, the Wars of the Roses. Okay, great. You've got a cannon that can shoot into the enemy lines, which is really nice and destructive—by the way, the arcing cannon shot is great for drama and sieges, but for sheer carnage, you can't beat a shrapnel shot headed straight into a mass of soldiers. You know how to do that, and your thousands of musketeers are at the top of their game. Should be an easy win, right?
Maybe not. Remember that we're dealing with pre-modern war. Anything can happen, and your fancy weapons have an awful lot of ways to become useless. Rain is the biggest factor, as black powder won't ignite properly if it's wet. ("Keep your powder dry" wasn't referring to talcum.) Wind can affect long-range shots, as can simple ballistic effects that we now understand on a better level than any 15th-century Englishman. This also holds true for muskets, as they were smoothbore, lacking the stabilizing effect of a rifled barrel.
In perfect weather, your gunners have a better chance, but they need to hurry, and they need to hit. Neither was a given. Barrels could clog, powder could fail to light, a soldier could drop his fuse. And sometimes people just plain miss. All that combined to make a salvo very imperfect. In the face of an oncoming charge, though, they may not get another chance. If all else fails, the infantryman might turn to a bayonet, at which point he becomes nothing more than a spearman.
Now add magic
All in all, while gunpowder did make a huge impact on the battlefields of the 14th, 15th, and 16th centuries, it didn't render them completely unrecognizable when compared to those of ages past. Things changed, and some of the changes were indeed revolutionary, but war…war never changes. Isn't that how the saying goes?
Guns don't end fantasy. They just end the traditional sort of fantasy that revolves around feudal society as practiced in England circa 1200. For any other kind, they're nothing more than another tool in the writer's arsenal, although they do need some special care.
First off, remember that black powder requires some knowledge of chemistry just to invent. Sure, a lucky alchemist might stumble upon the right formula, but he'll definitely want to explore it in a more rigorous way after that. If anything, it's possible that the invention of gunpowder may create the science of chemistry in your setting. It wouldn't be beyond reason, especially in a warrior society. Or simply one that's at war a lot.
Next, think about the materials involved. While the chemical formula for saltpeter wasn't known at the time, everyone who knew of the stuff recognized its rarity. Other than the "French" method (probably about as French as the fries) that amounted to distilling human excrement, the best way of getting a powder-worthy nitrate was to find a natural deposit somewhere. So those will be valuable. Sodium nitrate can accumulate in coastal deserts like the Atacama; caves full of bats provide a potential source for the potassium sort. And don't forget about sulfur. Pure sulfur is rare. Until your fantasy civilization has a reliable method of breaking it out of something like pyrite, the best places to look are near hot springs and volcanoes.
Once the secret gets out and the materials are found, the effect of gunpowder on a society still isn't set in stone. A sufficiently honorable culture might shun the weapons; conversely, a seriously devout nation may see them as tools of the devil. Either possibility means that guns will have a slow start. They'll be relegated to thieves and other outlaws in the beginning, most likely, only entering the battlefield once the powers that be recognize their value.
The few years after their introduction into warfare are the most dramatic. Though guns might be unreliable, the first army to use them effectively will see a huge advantage. Remember that a cannon starts as a shock weapon, something to instill fear. Handguns, by contrast, are more like crossbows: good in certain situations, more of a hindrance in others.
But the first tentative steps will soon turn into a stampede. City walls can't stand up to a cannon barrage, so they may get replaced by earthen ramparts or disappear entirely. The sword and shield can remain symbols of a gentleman or officer, but you'll see more skirmisher-type infantry in the ranks. And you'll eventually get ranks, as in multiple lines of soldiers firing in staggered time. Cavalry has a harder time of it—horses don't like the sound of a gun going off right behind them—so they'll take longer to become modernized. Expect a lot of dead mounts in the intervening period.
Adding in flashy magic of the D&D sort...doesn't change much. You'd think it would. After all, wouldn't it be easier to shoot the wizard from a distance before he starts casting a fireball? Yeah, that works, but it doesn't change the tactics much. If you think about it, and I mean really contemplate the situation, you'll come to the inevitable conclusion: an archmage on the battlefield, throwing fire and lightning everywhere, is (from a tactical standpoint) nothing more than a reskinned cannon. Unless some special rules apply, a bullet is going to do the exact same thing to his shield spell as an arrow would, while his recharge time (if any) is no different from the time it takes a team to reload their cannon. Looked at like that, you can consider the more powerful wielders of magic to be like gunpowder artillery, while the low-level warrior mages are closer to musketeers. And vice versa.
I think that's a very important point. Instead of treating guns as anathema, look at them from a different point of view, one you already know from fantasy.
Changes
In the social sphere, that rule of thumb doesn't apply. As we know from our modern world, guns are important. In the United States, they're a perennial point of political argument. Elsewhere in the world, they have been banned entirely. The reasons for this are worthy of their own post, but they boil down to a few simple factors.
Guns level the playing field. A single knight in armor can run through a line of peasants armed with nothing more than pitchforks and maybe a spear or two. If they knock him off his horse, no matter. He's still got the big sword, the sturdy mail, and most of all the training to hold his own when outnumbered by lesser foes. Give even one of them a gun, however, and everything changes. No longer can that knight assume he's safe, because he's not. He's vulnerable. That armor isn't going to help, he may not get close enough to use the sword, and no amount of practice is going to let you dodge bullets unless your name is Neo.
Guns get better. Medieval weaponry has a hard limit. Given the technology of the time, how much better can you make a sword? At a certain point, either the length or the weight becomes your limiting factor. But guns, being new in the time period we're discussing, have room to grow. In real life, they did so fairly quickly to start; it's reasonable to think the same would hold true in a fantasy world. You might not get cordite until a couple hundred years later, sure, but a shotgun, a howitzer, and some dynamite make up for that.
Guns are accessible. Firing a gun is easier than any other method of killing short of drone warfare. Making and caring for them are both learned skills; producing the powder necessary to use them is a task best left to experts. Yet the simple act of pointing and shooting is something anyone can pick up. With a little training, a company of soldiers becomes a fearsome force, a process so much more efficient than the path of swordsmanship.
How you handle these factors will determine what your post-gunpowder fantasy world looks like. If the materials, especially the components of powder itself, are hard to come by, progress will be slower, and those lands rich in saltpeter or sulfur will suddenly find themselves sitting on a new kind of goldmine. Make them more common, though, and you get an arms race.
You might even want to look at who gets gunpowder first. In our world, the Chinese invented it. Like many of their inventions—the compass, the printing press, and so on—their progress on guns stagnated when compared to the West. Now imagine a nation of hot-blooded, hotheaded warriors unlocking such secrets first. (On the other hand, the Mongols were early users, yet they didn't advance the science much.)
The interplay of guns and magic, assuming your fantasy setting has the latter, is harder to explain. Both will stand apart on the battlefield, though. They have similar natures, in that neither fits the mold of the traditional medieval warrior.
However you choose to do it, remember that the first guns are the beginning of a new era, not the end of a genre. Early gunpowder is more of an addition than a replacement. Over time, the evolution of gunpowder weaponry increases its use, accuracy, and lethality, until it becomes the only option. In the intervening generations, there's plenty of opportunity for good stories.
What if guns are the only way to kill demons? What if even a wizard's acolyte can create saltpeter from nothing? What if the invention of powder is the last straw, the final offense against nature that awakens the primal spirits of the earth? What if it's instead the turning point, the chance for an enslaved race to become free of its captors?
Fantasy is great because it offers us a glimpse of an entire world unlike our own in at least some way. I don't think "never inventing gunpowder" is that way, because a tool's value comes from how it is used. Guns are useful in real life and in stories.
Thanks again for reading. This one was longer, but it's a topic that I found interesting. The common viewpoint of fantasy as never advancing beyond the Game of Thrones era annoys me, while stories with dueling pistols, rifles, and even heavy weaponry grip me in a way I never understood until I read the term "riflepunk" somewhere on the internet a few years ago.
Whether or not you agree, I hope you found some food for thought in this entry. If you liked it, be sure to let me know with a comment. Share it far and wide, get your friends to subscribe to Hardcore Worldbuilding, and never forget to keep reading!