Jump to content

Recommended Posts

Posted

I checked the pixel and its color by using autoit.

Then in a func i have:

CODE

func start()

If pixelgetcolor( 200, 500) = 0x000000 Then

Run( "start.exe" )

EndIf

EndFunc

For some reason it does not check the pixel? Am i doing something wrong?

Posted

I checked the pixel and its color by using autoit.

Then in a func i have:

CODE

func start()

If pixelgetcolor( 200, 500) = 0x000000 Then

Run( "start.exe" )

EndIf

EndFunc

For some reason it does not check the pixel? Am i doing something wrong?

PixelGetColor() returns the value in decimal, not hex. Also, it's good practice to capitalize all of your code appropriately.

Posted

@ham

Works for me

start()

func start()
    If PixelGetColor(200, 500) = 0x000000 Then 
        ConsoleWrite("Color found" & @CRLF)
    Else
        ConsoleWrite("Color not found" & @CRLF)
    EndIf
EndFunc

@aggixx

You are right on that, but it will still work, try it yourself.

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...