World of Warcraft Forever API · C_ItemInteraction.md, for your AI
C_ItemInteraction
10 functions, 2 events, 3 tables, as Blizzard documents them for Forever 1.60.1 (70959).
Making an addon with an AI? Tell it: Read https://wowaddons.gg/agents.md, then make me a World of Warcraft Forever addon that …, try it with me in the game, and publish it. It checks every call against this API before you try it in the game, then publishes it here. How it works.
Functions
C_ItemInteraction.ClearPendingItem
C_ItemInteraction.ClearPendingItem()
C_ItemInteraction.CloseUI
C_ItemInteraction.CloseUI()
C_ItemInteraction.GetChargeInfo
chargeInfo = C_ItemInteraction.GetChargeInfo()
Returns
chargeInfo | ItemInteractionChargeInfo |
|---|
C_ItemInteraction.GetItemConversionCurrencyCost
conversionCost = C_ItemInteraction.GetItemConversionCurrencyCost(item)
Arguments
item | ItemLocation |
|---|
Returns
conversionCost | ConversionCurrencyCost |
|---|
C_ItemInteraction.GetItemInteractionInfo
info = C_ItemInteraction.GetItemInteractionInfo()
Returns
info | ItemInteractionFrameInfo may be nil |
|---|
C_ItemInteraction.GetItemInteractionSpellId
spellId = C_ItemInteraction.GetItemInteractionSpellId()
Returns
spellId | number |
|---|
C_ItemInteraction.InitializeFrame
C_ItemInteraction.InitializeFrame()
C_ItemInteraction.PerformItemInteraction
C_ItemInteraction.PerformItemInteraction()
C_ItemInteraction.Reset
C_ItemInteraction.Reset()
C_ItemInteraction.SetPendingItem
success = C_ItemInteraction.SetPendingItem([item])
Arguments
item | ItemLocation may be nil |
|---|
Returns
success | bool |
|---|
Events
ITEM_INTERACTION_CHARGE_INFO_UPDATED
No payload.
ITEM_INTERACTION_ITEM_SELECTION_UPDATED
itemLocation | ItemLocation may be nil |
|---|
Tables
ConversionCurrencyCost structure
currencyID | number | |
|---|---|---|
amount | number |
ItemInteractionChargeInfo structure
newChargeAmount | number | |
|---|---|---|
rechargeRate | number | |
timeToNextCharge | number |
ItemInteractionFrameInfo structure
textureKit | textureKit | |
|---|---|---|
openSoundKitID | number | |
closeSoundKitID | number | |
titleText | string | |
tutorialText | string | |
buttonText | string | |
interactionType | UIItemInteractionType | |
flags | UIItemInteractionFlags | |
description | string may be nil | |
buttonTooltip | string may be nil | |
confirmationDescription | string may be nil | |
slotTooltip | string may be nil | |
cost | number may be nil | |
currencyTypeId | number may be nil | |
dropInSlotSoundKitId | number may be nil |