Heya all! Made a custom event to handle some commands in one of my macros. When the event fires, it loops endlessly. I had to put in a
/doevents flush to stop it from happening. Is that the proper way of doing it? Here's a snipped to illustrate my question:
Code: Select all
#turbo 15
#Event CastCommand "#1# tells you, 'CAST #2# [[#3#]]'"
Sub Main
/echo Test Event Macro initiated.
:MainLoop
/doevents
/delay 10
/goto :MainLoop
/return
Sub Event_CastCommand(CastLine, CastTell, CastSpell, CastTarget)
/echo CastCommand: ${CastLine}
/echo Tell = ${CastTell}, Spell = ${CastSpell}, Target = ${CastTarget}
/delay 10
/doevents flush
/return
It seems a little extreme to have to do that. A quick search didn't turn up too much, so I'm wondering if the flush is really necessary or if there's some smooth command I should be using to clear this particular event.