包含窗体操作、循环、子函数范例
//
VBS requestTimes = 0
VBS iPathTimes = 59
VBS iPath = 0
VBS iWant="f_f25_,f_f4_,f_f43_,f_f4_,f_ll_"
VBS iWant=iWant+",f_f5_,f_f16_,f_f23_,f_f30_,f_f40_,f_f45_,f_f46_,f_f47_,f_f52_"
VBS iWant=iWant+",f_yry,f_gg,f_bf,f_nn,f_xdt,f_xmy,f_ttsy"
VBS iNext="0,30,2,40,2,45,2,55,2,70,2,2,2"
VBS waitTime=Split(iNext,",")
VBS getMyFish = 0
//
While 1=1
If requestTimes>=11
VBS getMyFish = 0
VBS requestTimes = 1
VBS iPathTimes = iPathTimes + 1
Else
VBS requestTimes = requestTimes + 1
EndIf
If iPathTimes \ 30 mod 2 > 0
iPath = 4
Else
iPath = 4
EndIf
VBS filePath="\newCase"&iPath&"\hdprev"&requestTimes&".x-amf"
Gosub sendRequestData
Gosub findResponseHwnd
If requestTimes mod 2 > 0
Gosub fishCatcher
EndIf
Gosub closeResponseHwnd
If getMyFish = 1
If requestTimes<11
nextTime = waitTime(requestTimes)
Gosub waitNextRequest
Else
Gosub closeResponseHwnd
EndIf
Else
If requestTimes<9
nextTime = waitTime(requestTimes)
Gosub waitNextRequest
Else
requestTimes = 11
Gosub closeResponseHwnd
EndIf
EndIf
EndWhile
//
EndScript
//
Sub findResponseHwnd
VBS flgsTime = 1200
VBS resHwnd = 0
While resHwnd = 0
VBS flgsTime = flgsTime - 1
Plugin resHwnd = Window.Find(0,"Response")
If resHwnd = 0
Delay 100
EndIf
If flgsTime < 0
VBS resHwnd = -1
EndIf
EndWhile
If resHwnd = -1
Gosub sendRequestData
Gosub findResponseHwnd
EndIf
Return
//
Sub closeResponseHwnd
VBS resHwnd = 0
VBS mainHwnd = 0
Plugin resHwnd = Window.Find(0,"Response")
Plugin mainHwnd = Window.Find(0,"Poster")
While (resHwnd > 0 and mainHwnd <> resHwnd)
VBS isWin = 0
Plugin isWin = Window.IsWindow(resHwnd)
If isWin > 0
Plugin Window.Active(resHwnd)
Delay 100
KeyDown 18,1
KeyPress 115,1
KeyUp 18,1
EndIf
Plugin resHwnd = Window.Find(0,"Response")
EndWhile
Return
//
Sub sendRequestData
MoveTo 56,278
LeftClick 1
Delay 100
KeyPress 9,1
Plugin Sys.SetCLB(filePath)
Delay 100
KeyDown 17,1
KeyPress 86,1
KeyUp 17,1
Delay 100
KeyDown 16,1
KeyPress 9,2
KeyUp 16,1
Delay 100
KeyPress 13,1
Delay 200
Return
//
Sub fishCatcher
MoveTo 862,392
LeftClick 1
Delay 500
LeftClick 3
Delay 100
KeyDown 17,1
KeyPress 67,1
KeyUp 17,1
Delay 100
Plugin text = Sys.GetCLB()
Delay 100
Gosub getMyFish
Return
//
Sub getMyFish
//Gosub fishLog
VBS tryList=Split(iWant,",")
VBS i=0
While i<=Ubound(tryList)
按键精灵VBS脚本实例源码及详解_IT/计算机_专业资料。按键精灵VBS脚本实例源码及详解这个例程有源码和详尽的注释,讲解由浅入深,很好理解,我照着上面的例子自己也编...
按键精灵脚本编写方法_计算机软件及应用_IT/计算机_专业资料。按键精灵脚本编写...//把当前鼠标位置的 x 和 y 坐标放在变量 mx 和 my 中 脚本例子: (7.x...
按键精灵使用教程及实例_IT/计算机_专业资料。按键精灵教程按键精灵破解版可以帮你操作电脑。不需要任何编程知识就可以作出功能强大的脚本。只要您在电脑前 用双手...
第1 课:零编程学会补红蓝脚本的制作 补红蓝脚本的制作 我们应该知道,按键精灵...先来做一个实际的例子: If 1>3 MessageBox "不成立" Else MessageBox "成立...
按键精灵网游脚本编写教程_IT/计算机_专业资料。按键精灵编写网游脚本教程,在...二、鼠标命令命令名称: 命令功能: 命令参数: 返回值: 脚本例子: (8.x语法)...
按键精灵常用功能-详细解说[1]-键盘动作-4 个功能 (1)单个按键的模拟-模拟... 按键精灵VBS脚本实例源码... 27页 1下载券 按键精灵命令大全 11页 1下载券...
那么,按键精灵具体能帮我们干什么呢?我们来列举几个例子来说明下。 * 网络游戏中可作脚本实现自动打怪,自动补血,自动说话等; * 办公族可用它自动处理表格、文档...
在本章里,会以补红蓝脚本做为切入点,实际讲述各种脚本的编写方 法。并避开枯燥的编程概念讲解,以实为主,通过大量的应用例子掌握按键精灵。 首先出现在本节中的...
屏幕 X 坐标 参数 2 整数型,屏幕 Y 坐标 参数 3 字符串型,颜色 16 进制值 参数 4 整数型,判断条件 返回值 脚本例子 按键精灵 8 及以上语法 无 复制代码...
热门文档