Jump to content

Recommended Posts

Posted

Sleep(3000)
MsgBox(0,"Starting", "We are ready to start!")
$s=1
While $s=1
    $reaction = PixelSearch("413,551", "621,477", "849,559", "656,656", 0x00CC33)
    MouseClick("left", $reaction[0], $reaction[1])
WEnd

What im trying to do is loop it so that it constantly searches for the pixels, im having major trouble with this

Posted (edited)

From the Help File for PixelSearch:

Return Value

Success: Returns a two-element array of pixel's coordinates. (Array[0] = x, Array[1] = y) 
Failure: Sets @error to 1 if color is not found.

I would presume that you need to change it to:

Sleep(3000)
MsgBox(0,"Starting", "We are ready to start!")
$s=1
While $s=1
    $reaction = PixelSearch("413,551", "621,477", "849,559", "656,656", 0x00CC33)
    If Not @error Then
        MouseClick("left", $reaction[0], $reaction[1])
    EndIf
    Sleep (100) ; Thrown in just for good, non-cpu-hogging measure
WEnd
Edited by exodius
Posted

well to start off the..

$s=1
While $s=1oÝ÷ ÙÆ§mæ®¶­sgvÆRb33³b33°¢ââà¢ââà§vVæoÝ÷ Ù©Ý~í+ºÚ"µÍ  ÌÍÜXXÝ[ÛH^[ÙXÚ
    ][ÝÍLË
MLI][ÝË   ][ÝÍK

ÍÉ][ÝË  ][ÝÎ
K
MNI][ÝË   ][ÝÍM
M][ÝËÐÌÌÊB[ÝÙPÛXÚÊ   ][ÝÛY ][ÝË  ÌÍÜXXÝ[ÛÌK    ÌÍÜXXÝ[ÛÌWJoÝ÷ Û*.®j,¶X¤z zÛbaÇ«®êº

* If you have any questions feel free to ask!

Hope this helps! :)

- John

Latest Projects :- New & Improved TCP Chat

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
×
×
  • Create New...