Is it possible to link lootlinks in macro? I would like it because i sell alot of stuff so it would be easy to just click 1 macro..
Is it possible to link lootlinks in macro? I would like it because i sell alot of stuff so it would be easy to just click 1 macro..
not possible : (
/pat
i only know of a regular sell vendor trash macro (found everywhere online)
found at wow forums (google ftw)Code:/run for bag=0,4,1 do for slot=1,GetContainerNumSlots(bag),1 do local name=GetContainerItemLink(bag,slot) if name and string.find(name,"ff9d9d9d") then DEFAULT_CHAT_FRAME:AddMessage("- Selling "..name) UseContainerItem(bag,slot) end end end
should be possible if the locations of the items are fixed, and then using the location as a reference, the sell macro above works by scanning all item strings in your inventory and check checking for the grey text. and then it just tries to use it, ie. rightclick it. and if vendor is up, it sells.
Try this macro and substitute bag and slot with some numbers that has an item. Guess you could also loop a bag or even use a mouseover function and build an array.
Anyways, couldnt remember whether to paste an itemLink or an itemString, but I think it's the String we want, not sitting at wow atm and all.
Code:/script local myLink=GetContainerItemLink(bag,slot) local found, _, itemString = string.find(myLink, "^|c%x+|H(.+)|h%[.+%]") SendChatMessage("Selling: " .. itemString);
bagID are :
* 0 for the backpack
* 1 to 4 for the bags on the character (numbered right to left)
* -2 for the keyring
While the bank is opened:
* -1 for the bank content
* 5 to 11 for bank bags (numbered left to right, was 5-10 prior to 2.0)
slot
Integer - slot inside the bag (top left slot is 1, slot to the right of it is 2).
Just showing how you could change it from the say channel to the trade channel.Code:/Script local myLink=GetContainerItemLink(bag,slot) local found, _, itemString = string.find(myLink, "^|c%x+|H(.+)|h%[.+%]") SendChatMessage("Selling: " .. itemString, "CHANNEL", nil, GetChannelName("Trade"));
Hope it gave you some ideas anyway.
It's possible, you just have to run another macro in order to create the macro.
/run CreateMacro(" ",1,"/2 WTS .. <Shift-click link here>.. blah blah 250g",1,1)
Open your macro dialogue window and you'll see a new macro there with the text "/2 WTS [Item Link] blah blah 250g". Knock yourself out, kiddo.