Page 1 of 1
Feature Request: /mqpause #
Posted: Thu Jul 20, 2017 4:59 pm
by jdestefx
In addition to an on/off parameter, have it recognized a deci-second param.
ie. /mqpause 20
Re: Feature Request: /mqpause #
Posted: Thu Jul 20, 2017 7:05 pm
by JudgeD
It's called /delay
Re: Feature Request: /mqpause #
Posted: Fri Jul 21, 2017 11:47 am
by jdestefx
That's different. I don't want a serial pause. I want to freeze a macro while I issue other commands briefly.
Re: Feature Request: /mqpause #
Posted: Fri Jul 21, 2017 5:40 pm
by MacQ
I realize this is not as clean as your suggestion of adding a timer value to /mqpause ##, but until/if that feature is added, you could probably accomplish something similar by setting up an #Event in your macro.
You might trigger the #Event with some command like a tell, a say, or even a command from EQBC which would cause a pause (loop) until another #Event breaks that loop. While macro is in the loop, you could execute the commands you want to execute (I assume you are not wanting to start another macro), then issue a different command (an #Event trigger), intercepted by an #Event, to break the loop.
I have macros that loop until certain events transpire, a bit different that I am suggesting, but my point is that I routinely execute commands while that macro is running so the basic concept is doable.
Just make sure you don't create a loop that will "drain" your CPU.
Re: Feature Request: /mqpause #
Posted: Wed Jul 26, 2017 3:48 pm
by Chatwiththisname
jdestefx wrote:That's different. I don't want a serial pause. I want to freeze a macro while I issue other commands briefly.
closest thing to that is /timed I believe
http://macroquest2.com/wiki/index.php/Timed
you could /multiline ; /timed 10 /mqp off ; /mqp on
or something like that I suppose?
Re: Feature Request: /mqpause #
Posted: Wed Jul 26, 2017 9:58 pm
by dewey2461
Add the /mqpause # command do your macro.
Your main macro probably has something like :
Code: Select all
| Do some setup stuff here
:MainLoop
| Do stuff all the time
| Do some more stuff
/goto :MainLoop
Add a subroutine that you bind to the /mqpause command which sets a variable mPause which can be either:
0 = Running normal ( OFF )
TimeStamp = Paused until current time > TimeStamp
MAX_INT = Paused - no timer
and in your main loop you call a subroutine that :
Code: Select all
:LoopPaused
/if ( ${mPause} == 0) /return
/if ( ${mPause} < "Current Time" ) /return
/goto :LoopPause
( I forget which TLO has the current time , think it is ${MacroQuest.XXX} ... )