Warlock (Dungeons & Dragons)

The warlock is a playable character class in the Dungeons & Dragons fantasy role-playing game. It was introduced as a non-core base class in the supplemental book Complete Arcane for the 3.5 edition of Dungeons & Dragons. In 4th and 5th edition, the warlock is a core class.

Dungeons & Dragons 3rd edition (2000-2007)
Unlike sorcerers and wizards, who approach arcane magic through innate ability or a book of learned magic, a warlock invokes magic through their darkened soul. By harnessing their innate magical gift, warlocks can perform spell-like feats and abilities; since they are not users of true spells in the traditional sense, they can use their invocations while wearing light armor. Warlocks are often evil or chaotic in alignment.

Warlocks in Dungeons & Dragons receive their abilities through the influence of some unearthly being such as a Demon or Fey. They are either born with these powers or receive them through a fell pact, which turns their soul into a dark font of eldritch powers. Warlocks do not cast spells, but instead use spell-like abilities called "invocations", which represent the tapping of the power granted to the warlock. The most important of these abilities is the "eldritch blast" which is the warlock's main offensive ability, firing a blast of magical energy at the target. The blast deals 1d6 damage at first level and improves by 1d6 at each odd-numbered level after first. The blast is a ranged touch attack requiring a standard action and is a spell-like ability. Warlocks also have other minor, non-invocation abilities as they progress in level: energy resistance, inhumanly tough skin, unnaturally fast healing, and the ability to force magical items to do their bidding, to name a few.

The major difference that Warlocks have from all other Dungeons & Dragons magic users is their ability to use their invocations "at will," without a limit on the number of times an invocation can be cast. In contrast, a wizard or sorcerer can cast a set number of spells every day from a wider selection of spells than a warlock. The Warlock has a caster level, not a spellcaster level, limiting prestige class choices. However, some newer releases such as Complete Mage and Tome of Magic have provided additional materials for Warlock characters to build upon.

Invocations come in four power levels: least, lesser, greater, and dark. There are three categories of invocations as well: blast shape invocations, which modify the range and area of effect of the eldritch blast, essence invocations, which grant effects or modify the damage type of the eldritch blast, and general invocations which provide utility abilities such as flight and invisibility.

Dungeons & Dragons 4th edition (2008-2013)
In 4th edition, the warlock's powers are known as spells, and use the standard power system. The warlock has many different unique abilities, though a warlock's trademark ability is still Eldritch Blast. They can also deliver various effects through Warlock's Curse. The Warlock's other class features make them more accurate at ranged attacks when no ally is closer to their target and allow them to gain concealment whenever they move a sufficient distance. Almost all of the warlock's attack powers depend on charisma or constitution for accuracy and damage, with some powers gaining bonuses from intelligence.

The specific source of the warlock's power is defined as a Pact (with a non-divine supernatural entity or power), which affects at-will power options and makes certain powers more effective and provides a pact boon, an effect which is triggered whenever a cursed enemy is killed or incapacitated. There are six Pacts:
 * The Star Pact is made with an entity from the Far Realm or a star located near it, which grants powers of grand revelations from the stars that madden foes. Star Pact warlocks can use either Constitution or Charisma for their attacks. There are also Star Pact spells which use Intelligence for attack rolls.
 * The Fey Pact, forged with an amoral power of the Feywild, giving the user access to both wondrous and dangerous spells of the Faerie realm. Fey Pact warlocks use Charisma for their attacks.
 * The Infernal Pact represents an agreement with a devil of the Nine Hells, giving one powers of hellish and demonic proportions. Infernal Pact warlocks use Constitution for their attacks.
 * The Dark Pact is made with powerful residents of the Underdark and the Abyss, which grants spells of plagues, illness and disease. This was presented in the Forgotten Realms Player's Guide. Dark Pact warlocks use Charisma for their attacks.
 * The Vestige Pact, presented in the Arcane Power supplement, represents an agreement with vestiges, arcane "echoes" of once-great individuals and powers, allowing the Warlock to act as a spirit medium through which entities manifest their powers.
 * The Sorcerer-King Pact is included in the Dark Sun Campaign Setting. This pact is made with a Sorcerer-King of Athas, giving access to abilities that destroy and defile. Sorcerer-King Pact warlocks can use either Constitution or Charisma for their attacks.
 * The Gloom Pact is made with creatures of the Shadowfell, which gives the ability to connect with the shadows and use them to bind foes to them.
 * The Elemental Pact which allows Warlocks to draw their power from ancient Primordials in the Elemental Chaos, which in turn gives them chaotic elemental powers.

Tieflings and gnomes have racial bonuses to both intelligence and charisma (two key warlock attributes). In 4th edition a warlock's role is striker, meaning they are designed to deal heavy damage while avoiding retaliation. Warlocks also have many exotic powers that have bonus effects; such as Eyebite which makes the warlock invisible for one turn if it hits. Many of the Warlock's powers allow them to move as part of an attack or to move in an unusual manner, such as flight or teleportation.

In the 4th edition Essentials line, the Hexblade and Binder were released as a variant of the warlock.

Dungeons & Dragons 5th edition (2014-)
The warlock has been included as a character class in the 5th edition Player's Handbook.

The warlock returns as a core class in the Player's Handbook, with three options for its type of pact (Pact of the Chain, Pact of the Tome, and Pact of the Blade), and three options for its patron:
 * The Great Old One
 * The Archfey
 * The Fiend

Warlocks with a patron of the Archfey make pacts with powerful lords of Faerie, wild incarnations of the forces of nature, to gain their power; those with the Fiend patron make deals and bargains with infernal powers such as Demon Lords and Princes of Hell for magic; and those with the Great Old One patron draw their magical power from the Far Realm, strange, dark gods of entropy such as Tharizdun, or even eldritch alien beings, and are often on the verge of insanity.

Other media
Warlocks (3.5 edition) are featured in the Neverwinter Nights 2 video game from Obsidian Entertainment.