如题,BGCP2后台找图插件,图片能加载成功,但是后台找图时找不到,返回x,y都是-1,这个是什么问题,我刚学的萌新,真的找不到办法了,求求大佬来帮我看一下吧。Dim Hwnd
Call 获取句柄
Sub 获取句柄
Hwnd = Plugin.Window.Find("Chrome_WidgetWin_0", "雷霆战机")
TracePrint Hwnd
Call 后台找图
End Sub
Sub 后台找图
BMPArray= Plugin.BGCP2_02.LoadBMP("C:\Program Files (x86)\按键精灵\按键精灵2014\screen\雷霆战机\好友竞赛.bmp")
If IsArray(BMPArray)=False
MsgBox "载入图片失败",4096
EndScript
Else
Call Plugin.BGCP2_02.FindPicture(hwnd, 0, 0, 439, 824, BMPArray(0), 10, 0.8, x, y)
If x>= 0 And y>= 0 Then
MsgBox(x&","&y)
End If
TracePrint x
TracePrint y
Call Plugin.BGCP2_02.FreeBMP(BMPArray)
End If
End Sub