(Relatively) simple script help
Hi all,
VERY knowledgeable forum here! Hoping you guys can help. Link to post on official wow forums:https://us.battle.net/forums/en/wow/...?page=1#post-3 Text of that post here in case you don't want to click over: Addon AutoVendor allows me to add/remove things from a list of 'safe to vendor' items. Anything on this list is automatically vendored for me. To get items on this list is manual, by typing "/av junk " and then shift clicking the item, which adds the item name, and pressing enter. Example "/av junk [Pygmy Oil]" will add it to the list. One note is that you cannot simply TYPE the [Pygmy Oil], it must be an item link. What I want is to create a macro where I can hover over the item, press the macro button, and have it type out the "/av junk " and link the item I'm hovered over. I didn't get much help from that forum (Not sure why I thought I would), so I'm hoping you guys can assist. Is what I want to do even possible? |
I'm not sure macros are capable of doing that. But, what you could do is contact the developer of the addon and see if they can add that feature in.
|
I don't see why not. You'd just have to grab the itemlink from the tooltip (local itemName, ItemLink = GameTooltip:GetItem() ). If you know the call that occurs from the command line code you can write a tiny macro script to call it and pass in the item link.
Edit: Nope, you can't. The AV:ToggleJunk() function contains the below line, which could be formed to pass in item name and itemid from gametooltip:getitem()... Lua Code:
...however, listToggle is a local function, so you can't call it from a /script macro. Lua Code:
You'll have to contact the author to have them add the function, or you could a function yourself to your local copy of the code. Edit2: This might work. It's dry-coded (I can't test it atm) but it might work. Your macro should look like: /script AV:ToggleJunkFromTooltip() Lua Code:
|
Thanks for the responses guys.
Although not the answers I was hoping for, it's nice to know and not be in the dark. |
That bit of code I put up, you can edit the file yourself and just paste that is on the end, then put the /script snippet into a macro and you have the functionality you wanted, even if the author has absconded to count the fjords instead if updating the addon.
|
All times are GMT -6. The time now is 10:51 PM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI