Jump to content

Recommended Posts

Posted

How would you do something like:

:) If PixelGetColor(x,y) <isn't> 0xXXXXXX AND PixelGetColor(x,y) = 0xXXXXXX Then

I tried:

:) If X Not Y Then

, but it doesn't work and there doesn't seem to be an operator that works for it.

Posted (edited)

I think you would need this:

$variable= PixelSearch ( left, top, right, bottom, color [, shade-variation] [, step]] )
If @error then
MsgBox (0, "Pixel Not Found", "Error, PixelColor was not found")
EndIf

:)

EDIT: It searches for the pixel color provided for the certain area given, and if it is found, it doesn nothing (You can make it do anything you want, this is just an example...), but if it doesn't find the pixel color provided, a MessageBox appears and states that the color was not found...Thats what you wanted right?

EDIT2: Here:

$variable= PixelSearch ( left, top, right, bottom, color [, shade-variation] [, step]] )
If @error then
MsgBox (0, "Pixel Not Found", "Error, PixelColor was not found")
If not @error then
 MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1])
EndIf

Now that will tell you if the pixels were found, it will tell you the coordinates where they were at. :)

EndIf

Edited by layer
FootbaG
Posted

I think you would need this:

$variable= PixelSearch ( left, top, right, bottom, color [, shade-variation] [, step]] )
If @error then
MsgBox (0, "Pixel Not Found", "Error, PixelColor was not found")
EndIf

:)

<{POST_SNAPBACK}>

Thanks, so

:) $variable= PixelSearch ( left, top, right, bottom, color [, shade-variation] [, step]] )

;) If $varible = @error AND PixelGetColor(x,y) = 0xXXXXXX Then

would work?

Posted (edited)

If you're just asking what the not equals operator is, it's "<>"

I can't really tell by the way you worded it.

Edited by db26

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
  • Recently Browsing   0 members

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