FindColor 0,0,1024,768,"0000FF",intX,intY
If intX > 0 And intY > 0 Then
End If
命令是这样的,在坐标0,0到1024,758区域内找色"0000FF",返回找到的坐标intX,intY
如果找不到的话返回值intx和intY的值都是-1
了解了返回值后你明白啦,假设你要找不到后鼠标单击某处:
FindColor 0,0,1024,768,"0000FF",intX,intY
If intX > 0 And intY > 0 Then
else
MoveTo 355, 583
LeftClick 1
End If
找不到的话x,y都等于-1
FindColor 0, 0, 1024, 768, "0000FF", x, y
If x = -1 and y = -1 Then
End If