Ok what i want to do with this? I will try explain my best. The guy in the middle is inside of a rectangle and the round balls are , let see..., well they can be gifts.
So what i wanna do is : i want the "guy" search for that round balls and then when he found they, i want he pick the gifts.
well i tried a few things , like pixelsearch & pixelchecksum but i cant get this to work.
Im asking then for a few ideas to make this work and few tips how i can make this possible.
Ty every1!
This is my code, hope can help some1 to tell me whats wrong or missing
Code:
HotKeySet("{1}","quit")
WinWait("test","")
WinWaitActive("test","")
sleep(500)
opt("mouseclickdelay",200)
opt("MouseClickDownDelay",200)
While 1
$box=PixelSearch(0,0,1280,800,0xFFFFC4)
if IsArray($box) = True Then
MouseClick("left",$box[0],$box[1])
sleep(500)
ElseIf IsArray($box) = False Then
MouseClick("left",(random(1070,1265)),(random(640, 756)))
sleep(5000)
EndIf
WEnd
Func quit ()
Exit
EndFunc
Ok, so i can now make the thing move but now im getting a problem.
When the "thing" starts walk around and pass for a gift box he just ignore the gift box >.<!
this is my main problem!
Can some1 tell me how to write the code to make the "thing" pick up the gift box and continue searching for more?
P.S: Couldnt remove the attachment, but is just a pic, dont need download since the pic is on top!