Set an override binding to a specific spell. Override bindings are temporary. The bound key will revert to its normal setting once the override is removed. Priority overrides work the same way but will revert to the previous override binding (if present) rather than the base binding for the key. See ClearOverrideBindings() to remove bindings associated with a given owner.


See also Keybind functions.

Signature:

SetOverrideBindingSpell(owner, isPriority, "key", "spellname")

Arguments:

  • owner - The Frame (or other widget) object responsible for this override (table)
  • isPriority - True if this binding takes higher priority than other override bindings; false otherwise (boolean)
  • key - A key or key combination (e.g. "CTRL-2") (string, binding)
  • spellname - Name of a spell, or nil to remove the override binding (string)

Examples:

-- Set up Shift-2 to cast Prayer of Mending as an override binding
-- owned by PlayerFrame
SetOverrideBindingSpell(PlayerFrame, 1, "SHIFT-2", "Prayer of Mending")

-- Clear PlayerFrame's override bindings
ClearOverrideBindings(PlayerFrame)