Jump to content

How can i do this?


Recommended Posts

HotKeySet("{PAUSE}", "mExit")

MouseClick("left", 568, 23, 1)

While 1

If PixelGetColor(120,777) = Dec("7b7984") Then

Sleep(500)

Send("{F1}")

Sleep(7000)

Send("{F2}")

Sleep(200)

Send("{F1}")

Sleep(7000)

Send("{F2}")

Send("{F2}")

Sleep(200)

Send("{F2}")

EndIf

If PixelGetColor(368,707) = Dec("00f742") Then

Sleep(5000)

Else

MouseClick("right", 75,568, 1, 0)

MouseClick("right", 119,568, 1, 0)

EndIf

Wend

Func mExit()

Exit

EndFunc

ive finally got what i needed, but now for some reason (bolded part), when 368,707 is 00f742, it stops the mouseclicking, but not right away, the mouse still clicks a couple times before it stops... anyway i can make it stop faster? and also when 368,707 is no longer 00f742 it takes a couple secs till it resumes clicking... anyway i can speed these 2 processes?

Edited by lilandywandy
Link to comment
Share on other sites

;Just an idea

;Every other line type this

call("Check_pixel")

; then add this as a function

Func Check_pixel()

While 2

If PixelGetColor(368,707) = Dec("00f742") Then

Sleep(100) ; more or less time ???

EndIf

If Not PixelGetColor(368,707) = Dec("00f742") Then Return

WEnd

EndFunc

; ****** I cannot check this ***** Tweak as needed ******

; hope it helps... 8)

NEWHeader1.png

Link to comment
Share on other sites

Also, convert Dec("00f742") to 0x00F742

David Nuttall
Nuttall Computer Consulting

An Aquarius born during the Age of Aquarius

AutoIt allows me to re-invent the wheel so much faster.

I'm off to write a wizard, a wonderful wizard of odd...

Link to comment
Share on other sites

HotKeySet("{PAUSE}", "mExit")

MouseClick("left", 568, 23, 1)

While 1

If PixelGetColor(120,777) = Dec("7b7984") Then

Sleep(500)

Send("{F1}")

Sleep(7000)

Send("{F2}")

Sleep(200)

Send("{F1}")

Sleep(7000)

Send("{F2}")

Send("{F2}")

Sleep(200)

Send("{F2}")

EndIf

If PixelGetColor(368,707) = Dec("00f742") Then

Sleep(5000)

Else

MouseClick("right", 75,568, 1, 0)

MouseClick("right", 119,568, 1, 0)

MouseClick("right", 75,568, 1, 0)

MouseClick("right", 119,568, 1, 0)

MouseClick("right", 162,568, 1, 0)

MouseClick("right", 193,568, 1, 0)

MouseClick("right", 228,568, 1, 0)

MouseClick("right", 263,568, 1, 0)

MouseClick("right", 299,568, 1, 0)

MouseClick("right", 332,568, 1, 0)

MouseClick("right", 371,568, 1, 0)

MouseClick("right", 424,568, 1, 0)

MouseClick("right", 495,568, 1, 0)

MouseClick("right", 549,568, 1, 0)

EndIf

Wend

Func mExit()

Exit

EndFunc

ok this is what i have and its working fully and properly. Only 1 problem, on the "If PixelGetColor(368,707) = Dec("00f742") Then Sleep(5000)" it sleeps, but thing is it sleeps after the mouseclick cycle is over instead of sleeping right away when 368,707= 00f742..

any idea how i can make it sleep right away instead of finishing the clicks?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...