Ok, sooo, my programming skills are very basic and I cant make a script work, I want make a script that keep verifying If there is a determined color on a determined pixel, If yes, then click three times, If no, then keep verifying, basically a wait for pixel color.
Sorry If my english is bad, it isin't my mother languague, thank you for your help.
Wait for pixel color
-
- Posts: 3
- Joined: 22 Feb 2020, 20:55
Re: Wait for pixel color
Hallo,
try:
try:
Code: Select all
#Persistent
SetTimer, PixelColor, 1000
PixelColor:
PixelGetColor, Color, 200, 400
IF Color = 0xFFFFFF ;White
{
Click 3
SetTimer, PixelColor, Off ;end verifying
}
Else ;keep verifying
ToolTip, no click because the color is: %Color%
Return
-
- Posts: 3
- Joined: 22 Feb 2020, 20:55
Re: Wait for pixel color
Its not working, I aleardy changed the modes but it always detect a different color (slightly different) like, sometimes f8f8f8, then f8f8f9 its possible to add a color tolerance?
Re: Wait for pixel color
Then perhaps:
Code: Select all
#Persistent
SetTimer, PixelColor, 1000
PixelColor:
X := 200, Y := 400
PixelSearch,,,X,Y,X,Y, 0xFFFFFF, 4 ;tolerance = 4
IF !ErrorLevel
{
Click 3
ToolTip
;SetTimer, PixelColor, Off ;end verifying
}
Else ;keep verifying
{
PixelGetColor, Color, X, Y
ToolTip, no click because the color is: %Color%
}
Return
Who is online
Users browsing this forum: No registered users and 59 guests