Code: Select all
#Persistent
#SingleInstance, Force
CoordMode, Pixel, Screen
Loop {
WinWaitActive, Pokemon
SetTimer, Check
WinWaitNotActive
SetTimer, Check, Off
}
Check:
PixelSearch,,, 199, 50, 334, 50, 0x707070,, Fast
If !ErrorLevel
Return
PixelGetColor, GreenColor, 320, 50, RGB
If (GreenColor = 0x00C000)
Return
PixelGetColor, LightgreenColor, 310, 50, RGB
PixelGetColor, YellowColor , 255, 50, RGB
PixelGetColor, RedColor , 235, 50, RGB
If (LightgreenColor != 0x60C060 And YellowColor != 0xC0C000 And RedColor != 0xC03030)
ControlSend,, {f5}, Pokemon
Return
If (LightgreenColor != 0x60C060 And YellowColor != 0xC0C000 And RedColor != 0xC03030)
but only if they are within the specified coordinate below:
201, 46 to 311, 55
Can someone help me ?