This post has been edited 1 times, last edit by "Gorgar" (Jul 14th 2013, 5:52pm)
This post has been edited 1 times, last edit by "karmakarma" (Jul 18th 2013, 1:45pm)
UseItemByName() works just fine in both lua and a macro.
function UP()
UseAction(1)
end
Then in a macro create something like this...
/run UP
/wait 1
/run UP
/wait 1

That for loop is the basic idea, but you have the problem that this runs to fast. You can't make it work slower while keeping the mouse click context from within Lua. So it won't work in a nice way with one click for a full stack and detection whether there are items left, etc...If I try a /run for i=1,99 UseItemByName("Nocturnal Lantern Grass Sap") end
I only get one done, if I try add a wait 2 in there before end it doesnt unprocess that mat. Im guessing you can't have extra commands in the one loop. I am probably thinking it needs to be in an LUA but that is beyond me for now.
Anyone got some advice how to do this
Rightcklicking is basically the same as UseItemByName, just inventory index based (UseBagItem).UseItemByName() works just fine in both lua and a macro. However it won't do what you want because you have to right click the material you want to disassemble.
The first part is correct, but at the second you have to keep in mind that timing stuff in LUA causes usage of OnUpdate due to which you will loose the mouse click context. This would break everything here.You could however make a custom function/addon to do what you need and you can make it as long or short as you want including adding a wait timer into it.
This is correct again and you can use UseItemByName, ord UseBagItem, or ... instead of UseAction. It works because the wait is in the macro and not in the function. But this prevents the usage of loops, because there are no loops in macros, just Lua.Place a herb or other mat on your action bar in slot 1 for example then make this function
function UP()
UseAction(1)
end
Then in a macro create something like this...
/run UP
/wait 1
/run UP
/wait 1
Looking at the code he posted, he had a "one click for a full stack solution" in mind, which will not work.From how I read the OP's post was he wanted to make it so he clicks less not so he doesn't have to click at all cuz I'm sure he is aware it would be considered botting of course. However I recommend the custom function because it allows you to dramatically shorten the length of each line in the macro allowing for more commands.
I guess 99% that this won't work.Any attempt to unproccess mats must be done through either the keyboard or through clicks unless you go into extreme detail making an addon with a few timers and onupdate functions that constantly update every second or 2 after the function has started.
Well, eventhough this will work it is not allowed, as you are using 3rd party software to automate stuff. It's basically (and considered as) botting.Get a gaming mouse or keyboard "logitech" works best. Set it to repeat the last button pressed every 1.2 seconds and leave it where it is supposed to click and watch the magic unfold
The reason why you have to use this slash command instead of getting your equip automatically repaired is simple: Gameplay relevant stuff has to be initiated by a player's keystroke or mouse click. To implement time delays in addons, developers do NOT have any wait-like function you would have in a macro. Because of that developers basically use something, just that I do not want to go too deep into details, called "OnUpdate" which is triggerd every new frame drawn on your screen to get the elapsed time and basically create timers with that. But once you are using OnUpdate you will loose the keystroke or mouse click context and thus are not able to execute some stuff. As far as I know using items like potions and repair hammers is, just like casting spells, blocked from being used in a OnUpdate.