标签:
杂谈 |
分类: 按键精灵 |
Hwnd=Plugin.Window.Find("ApolloRuntimeContentWindow","PVP.net 客户端")
Winrect= Plugin.Window.GetClientRect(hwnd)//得到窗口客户端大小
xyarr= split(winrect, "|")
ux= CLng(xyarr(0)) : uy = CLng(xyarr(1))
MoveToux 647,uy 41//移动到PLAY
LeftClick1
Delay1000
MoveToux
329, uy
179//移动到人机对战
LeftClick2
Delay200
MoveToux
494, uy
151//移动到经典对战模式
LeftClick1
Delay200
MoveToux
682, uy
162//移动到召唤师峡谷
LeftClick1
Delay200
MoveToux
862, uy
151 //选择人简单还是一般
LeftClick1
Delay200
MoveToux
752, uy
710//点击 匹配队友
LeftClick1
Delay1000
TracePrint"进入匹配无问题"
Rem循环游戏
do
FindPicux 580,uy 346,ux 727,uy
425,"Attachment:\2.bmp",0.9,intX,intY//出现进入英雄图片
IfintX > 0 And intY > 0 Then
ExitDo
endif
loop
MoveToux
721, uy
483
LeftClick1 //进入选择英雄
Delay1000
MoveToux
320, uy
209//就选择随机英雄吧哈哈
LeftClick1
Delay500
MoveToux
864, uy
507//点击确定
LeftClick1
Delay2000
Delay180000//加载游戏窗口,就等3分钟吧
TracePrint"进入游戏没问题"
Call等待胜利
Delay2000
Sub等待胜利()
hwndb = Plugin.Window.Find("RiotWindowClass", "League of Legends (TM) Client")
Winrectb = Plugin.Window.GetClientRect(hwndb)//得到窗口客户端大小
xyarrb = split(winrectb, "|")
bx = CLng(xyarrb(0)) : by = CLng(xyarrb(1))
Do //好吧!在家里瞎走
MoveTo bx
622,by 410
RightClick 1
delay 1000
MoveTo bx 532,by 397
RightClick 1
delay 1000
FindPicbx
574, by
300, bx
704, by
362, "Attachment:\1.bmp", 0.9, intXb, intYb
If intXb > 0 And intYb > 0 Then //找到图片胜利
Exit Do
Winrect
xyarr
ux
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
TracePrint
Rem
do
FindPic
If
Exit
end
loop
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
MoveTo
LeftClick
Delay
Delay
TracePrint
Call
Delay
Sub
FindPic