Please help me with a difficult Marco

Hi. Conserning Macros. Im trying to remember how to set up a macro that would repeat itself forever untill i used /stopmacro. Like if i wanted to give my guild, warnings about upcomming raid like: Remember all to bring your flasks, etc. " And have the message being repeated every 5 minuts over and over and over…

It would probably have to simply have a line in there about the 5 min delay, and then to restart itself ???

I hope there are some good minds out there that can help me withouth over complicating it. Thank you

As far as I am aware the automated repeating nature you want in your macro is impossible using the client scripting language as it would basically allow unattended gameplay in other uses.

I know we was able to do something like it… becouse i would stand in Ogrimar and use a marco to send out guild info invites to everyone in /1 everly 5 minuts

Since there is no other place to ask I am sorry I cannot help with original but wish to ask casually in a thread for it:

I wanted to just as curiosity see how to map simple /emotes so I could maybe map them (in richer sense) like diablo (map keyboard keypad to a highly customized bar hide it from your eyes and go, usable with elvui or bartender for example)

I could not find out how to to insert [mod: tags into the macro with a simple /emote so it would work and not output the the jumbled mess into my chat. Usually say chat. Darn.

Also I am interested does the macro system in WoW classic allow macros to function individually. I mean that if I create a macro that waits for 55 seconds then outputs a sound to alert you at 56 then again at 59, would it, or would it not stop if another macro is used (any macro) - I come from FFXIV where I had such macro until I realized that other macros I started using overrode the one running macro and i still think it is a crying shame for that game.

It absolutely is possible. You do it the same way all addons do it: Use the lua scripting API to write a macro which creates a frame which, on its OnUpdate, calls a function which you have written to do whatever you need.

This only works if you need to do stuff that isn’t protected. Sending messages is not protected, but of course, casting spells is. Hopefully this is ample information for you to begin researching.

The only way to do that is to make a macro with announcing such stuff, and then use a different out of game software, that auto presses the hotkey. In game due to botting countermeasures it is not possible

How do you think addons do it then?

bacause the addon api is different then the ingame lua / macro options. Addons have more functionality possibility

Addons have more functionality possibility

Aside from a TOC and no character limit, addons are essentially the same as macros.

The challenge here is stuffing everything you need into a 255 character limit. What I do is split everything across a number of macros so that I have enough characters to write what I need.

Just like any addon, a macro can easily create a frame, and invoke a function which makes you post something in guild chat every 5 minutes.

/1 “info”
/ (THIS IS THE LINE I NEED, a timer like 60 sec before next line)
/clickButton8

ill put the macro on button8 and it should go on repeat.
Just missing the line that tells the macro to wait before next line.???

As Harrand said macros and addons are pretty much one of the same. Which means you will need to write a lua script to do it.

Posted by Corveroth on wowhead.

/run f=CreateFrame"Frame" t=GetTime() r=true f:SetScript(“OnUpdate”,if GetTime()>t and r then t=GetTime()+300 SendChatMessage(“MSG HERE”,“CHANNEL”,nil,GetChannelName(“Trade - City”)) end)

So this script should type “MSG HERE” into trade chat every 5 mins. It does this by checking the amount of time passed in seconds " t=GetTime()+300" change 300 to which ever interval you want “in seconds”, just don’t get yourself banned for spamming.

The script runs on the OnUpdate event so it should fire pretty fast.

To stop the script you need to set r to false
/run r=false

I haven’t tested this but this is how people did it back in the day.

You should not create new frame every time macro is pressed, because they are not destroyed and will eat memory. Especially frames with OnUpdate, because they might lower your FPS.

I suggest to find some mature addon for that task.

There is no timer in a macro. An addon may do it but macros can’t.

I think I made a simple /wait 5
and it waits for five seconds.
when I say timer that is what I meant, it just needs to wait for X seconds and then do something after that, not even automatically, or I mean, it does need to refresh for me, it just needs to remind me to.

No need to create a frame, just use the default frame’s OnUpdate

You may risk interrupting other functionality which uses the default frame by doing this. Be it addons, other macros etc… Paranoid to say, but nice to be on the safe side imo, there’s hardly a massive overhead to creating a frame.

That is not possible with a Warcraft macro and it counts as automation. Which program are you using for the macros?

You can trivially build a timer in a lua macro.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.