Ignoring event prob help

Help section from before the user variable changes that broke all macros

Moderator: MacroQuest Developers

Soulzek
flagrant idiot
Posts: 35
Joined: Mon Aug 26, 2002 2:12 pm
Location: The Void
Contact:

Ignoring event prob help

Post by Soulzek » Mon Sep 22, 2003 1:13 am

For unknown reason, this macro just skips the /doevent.... for instance, if i run this and the forge is being used, i would get the echo "passed the event, no good" when i should be getting "this echo is in the sub event". Any idea why its ignoring the "/doevent"'s i stuck above AND below the /click?

Code: Select all

#turbo
#event Forgeinuse "Someone else is using that"

Sub Main
:forgebad
/if $GM==TRUE /call GMDetect
/delay 5
/mouseto 52 456
/delay 5
[b]/doevents
/click left
/doevents[/b]
/delay 2
/echo passed the event, no good
/return

Sub Event_Forgeinuse
/echo this echo is in the sub event
/return
[b]Click on the image below to visit my site![/b]
[url=http://mywebpages.comcast.net/soulzek/][img]http://mywebpages.comcast.net/soulzek/title.png[/img][/url]

Soulzek
flagrant idiot
Posts: 35
Joined: Mon Aug 26, 2002 2:12 pm
Location: The Void
Contact:

Post by Soulzek » Mon Sep 22, 2003 1:19 am

Fixed, just needed to add a /delay 5 between the click and the /doevents to give it time to register the string...
[b]Click on the image below to visit my site![/b]
[url=http://mywebpages.comcast.net/soulzek/][img]http://mywebpages.comcast.net/soulzek/title.png[/img][/url]

Mckorr
Developer
Developer
Posts: 2326
Joined: Fri Oct 18, 2002 1:16 pm
Location: Texas

Post by Mckorr » Mon Sep 22, 2003 10:19 am

/click always has a lag to it. Usually a /delay 2 (at least for my machine) give enough time for the click to be executed and then recognized by EQ. Pretty much the delay is always necessary to give EQ a chance to recognize that the mouse has been clicked.

In other words, MQ is faster than EQ, so we have to script in delays to allow EQ to catch up.
MQ2: Think of it as Evolution in action.