As a rule, fantasy is about the most malleable genre of fiction ever conceived. With scores of different possibilities, it is inevitable that eventually a player in your game will want to use firearms (however advanced) in your campaign. In a campaign where all involved have agreed to a specific genre, such as my sword and sorcery style campaign, this will be less of an issue. If, however, you find yourself in a much more free-wheeling, open-genre endeavor, the issue of using a higher level of technology is surprisingly likely. My inner grognard is apt to say “No!” to such a player request, but as a person obsessed with the Spellburn podcast, I have recently adopted and attitude of “Yes, and…” It behooves me, then to consider how to incorporate this kind of technology into a traditional, fantasy role-playing game. Besides, to paraphrase the mighty Jim Wampler: If I can have a wizard with a laser-gun that is as happy as I get. So let’s turn consider some possible settings where this sort of thing is possible.
The Early-Modern Period
A personal favorite historical era of mine (yes, it is because of Spinoza and Leibniz), this is one of the easiest eras to incorporate firearms. In this period, firearms were coming increasingly available, but were very cost prohibitive. Conflicts such as the Thirty Years’ War often saw a mixture of firearms and more traditional weaponry being used side by side. Class divide was the reason why some possessed guns and others did not, so a DM can really flesh out the society of his/her campaign by incorporating this aspect. If this is a route you would like to go, I definitely recommend the combination of the AD&D 2nd Edition sourcebook A Mighty Fortress and the Gothic-horror inspired setting Ravenloft. Throw in some of Robert E. Howards Solomon Kane stories, and you have yourself a number of good sources to mine for ideas.
It is conceivable that your game takes place on earth (or some other world) in which there was a great disaster that lead to the sentient species going back to a more primitive state of technology (a la Thundarr the Barbarian). Even though most people will be using more antiquated weaponry, it is conceivable that there would be a several hidden caches of weapons scattered throughout the land. While it is unlikely that any character would begin the game with proficiency in such weapons, sentient species are generally very adaptable and could learn to use them over time. Depending on how far in the future you set the calamity, this setting could open up a lot of high-tech treasure just waiting to be found. In order to keep game balance, however, it is important to have the technology become irreparably damaged or possess a finite source of power and/or ammunition. Players who stumble across these artifacts will, as a consequence, have to be choosy when it comes to their use. Another possibility is to have “wizards” be merely those people who can invent, build, and utilize these technologies; this makes great antagonists, by the way.
The Dying Earth
Similar to the above in many respects, a dying earth setting is one in which firearms could be employed very easily. In these sorts of settings, the world itself is in its death-throws. Civilizations are collapsing due to war, decadence, and apathy. Perhaps there are a lot of geological phenomena that are constantly effecting the landscape, requiring great technologies to keep things together. In either case, resources will be very scarce and the average person will be unlikely to possess higher technologies. Given this, a character who uses firearms is likely to have a very interesting backstory.
The Lost World
It is, at this point, old hat to have an Atlantis/Lemuria/Thule type area which is cut off from the rest of the world by some sort of barrier (mystical or otherwise). While often we see these areas having creatures from a bygone era, it seems perfectly conceivable to me that they may also have a high level of technology. For instance, let us suppose that the inhabitants of the Lost World were the first sentient beings on the planet. It follows that they may be more technologically advanced than everyone else is. It could further be the case that, through the enlightenment of their society, they decided that their technology would negatively impact the development of other cultures (think the Prime Directive), and they chose to seclude themselves to keep from contaminating everyone else. On the flipside, perhaps their technology enabled them to conquer vast territories, and the other inhabitants of the planet joined together to repel and banish their former overlords. The lack of high technology elsewhere in the world in the latter case may be due to joint treaty or cultural stigma.
This is perhaps one of the most over-used tropes in fantasy gaming today: a world where magic users are politically dominant. One thing often overlooked in such a setting is the classism that would exist in this world. In all class-based societies, there needs to be a way in which the ruling class is able to keep their political hegemony; be it wealth, heredity, or (in this case) magic. If a society’s ruling class is indeed the ruling class because of magical ability, then there would certainly be barriers to most people acquiring said magic. As such, the ebb and flow would need to come up with some way of gaining power themselves, and the invention of gun powder would certainly do the trick. Of course, the possession of such technology would likely be illicit, so those with it would have to organize into underground movements, guerilla cells, or good old fashioned organized crime syndicates. This gives the DM and players an immensely rich atmosphere in which to play.