m
Move page script moved page API PickupInventoryItem to WoW:API PickupInventoryItem without leaving a redirect
No edit summary |
m (Move page script moved page API PickupInventoryItem to WoW:API PickupInventoryItem without leaving a redirect) |
||
| (4 intermediate revisions by 4 users not shown) | |||
| Line 1: | Line 1: | ||
PickupInventoryItem(slotId) | PickupInventoryItem(slotId) | ||
"Picks up" an item from the player's worn inventory. | "Picks up" an item from the player's worn inventory. This appears to be a kind of catch-all "pick up/activate" function. | ||
---- | ---- | ||
| Line 23: | Line 23: | ||
:You can use [[API GetInventorySlotInfo|GetInventorySlotInfo]] to get the slotId: | :You can use [[API GetInventorySlotInfo|GetInventorySlotInfo]] to get the slotId: | ||
{| cellpadding="1" align="center" | |||
|----- | |||
| GetInventorySlotInfo() || slotId | |||
|----- | |||
| AmmoSlot || 0 | |||
|----- | |||
| HeadSlot || 1 | |||
|----- | |||
| NeckSlot || 2 | |||
|----- | |||
| ShoulderSlot || 3 | |||
|----- | |||
| ShirtSlot || 4 | |||
|----- | |||
| ChestSlot || 5 | |||
|----- | |||
| WaistSlot || 6 | |||
|----- | |||
| LegsSlot || 7 | |||
|----- | |||
| FeetSlot || 8 | |||
|----- | |||
| WristSlot || 9 | |||
|----- | |||
| HandsSlot || 10 | |||
|----- | |||
| Finger0Slot || 11 | |||
|----- | |||
| Finger1Slot || 12 | |||
|----- | |||
| Trinket0Slot || 13 | |||
|----- | |||
| Trinket1Slot || 14 | |||
|----- | |||
| BackSlot || 15 | |||
|----- | |||
| MainHandSlot || 16 | |||
|----- | |||
| SecondaryHandSlot || 17 | |||
|----- | |||
| RangedSlot || 18 | |||
|----- | |||
| TabardSlot || 19 | |||
|----- | |||
| Bag0Slot || 20 | |||
|----- | |||
| Bag1Slot || 21 | |||
|----- | |||
| Bag2Slot || 22 | |||
|----- | |||
| Bag3Slot || 23 | |||
|} | |||
---- | ---- | ||
| Line 57: | Line 83: | ||
/script PickupInventoryItem(GetInventorySlotInfo("SecondaryHandSlot")) | /script PickupInventoryItem(GetInventorySlotInfo("SecondaryHandSlot")) | ||
The above attempts a main- | The above attempts a main hand/off-hand weapon swap. It will pick up the weapon from the main hand and then pick up the weapon from the off-hand, attempting to equip the main hand weapon to off-hand and sending the off-hand to main hand if possible. | ||
---- | |||
{{wowapi}} | |||