Jump to content
Sign in to follow this  
Evil_Has_Survived

Help Please

Recommended Posts

Evil_Has_Survived

hi I don't get it this script will click were your mouse is pointed it should aim for the pixel am I correct or not or am i being a :think: lol

Global $Paused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("{ESC}", "Terminate")



While 1
    $coord = PixelSearch(0,0,@DesktopWidth,@DesktopHeight,0x003FD0); will search your entire screen area for a pixel of the color 0x000000
    If IsArray($coord) = 1 Then
 MouseClick("left")
        EndIf
WEnd
Exit
Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        sleep(100)
        ToolTip('Script is "Paused"',0,0)
    WEnd
    ToolTip("")
EndFunc

Func Terminate()
    Exit 0
EndFunc

Thanks in advance

Share this post


Link to post
Share on other sites
Paulie

While 1
    $coord = PixelSearch(0,0,@DesktopWidth,@DesktopHeight,0x003FD0); will search your entire screen area for a pixel of the color 0x000000
    If IsArray($coord) = 1 Then
 MouseClick("left")
EndIf
Wend
I think that all you missing is that your not defing the array coords in MouseClick

you should be

While 1
    $coord = PixelSearch(0,0,@DesktopWidth,@DesktopHeight,0x003FD0); will search your entire screen area for a pixel of the color 0x000000
    If IsArray($coord) = 1 Then
 Mouseclick("left", $coord[0],$coord[1],0);<<<<<<<<<<<<
EndIf
Wend

something like that

I'm sure you knew that but weren't thinking straights :think:

Edited by Paulie

Share this post


Link to post
Share on other sites
herewasplato

greenmachine (and Paulie) posted the way to correct your code. greenmachine asked you questions in the comments of his code... are you going to try this code? or are you going to start another topic and ask the same question... again.

http://www.autoitscript.com/forum/index.ph...ndpost&p=177258


[size="1"][font="Arial"].[u].[/u][/font][/size]

Share this post


Link to post
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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.