Lore archive · Warcraft Wiki, 2023 dump
API EquipItemByName
Last wiki revision 2022-07-22
Equips an item, optionally into a specified slot. EquipItemByName(itemId or itemName or itemLink[, slot])
- (itemId or "itemName" or "itemLink"[, slot])
- itemId: - The numeric ID of the item. ie. 12345
- itemName: - The name of the item, ie "Worn Dagger". Partial names are valid inputs as well, ie "Worn". If several items with same piece of name exists, the first one found will be equipped.
- itemLink: - The itemLink, when Shift-Clicking items.
- slot: - The inventory slot to put the item in, obtained via GetInventorySlotInfo.
When in combat this function now "picks up" the item instead of equipping it, similar to PickupInventoryItem. Out of combat, the function behaves as expected. This change was made to address the issue of rogues using "poison swapping" addons to increase their DPS.
Source
https://warcraft.wiki.gg/wiki/API_EquipItemByName · retrieved 2023-11-13 · CC BY-SA 4.0
Converted from wikitext with templates, tables and images removed, so some sentences may be missing values.
This archive predates WoW: Forever. For collected gameplay facts see the Forever database. Search the archive.