当前位置:首页 » 网页前端 » crx按键脚本
扩展阅读
webinf下怎么引入js 2023-08-31 21:54:13
堡垒机怎么打开web 2023-08-31 21:54:11

crx按键脚本

发布时间: 2022-06-20 22:12:15

Ⅰ 按键精灵怎么循环找两张图片点击,代码怎么写

Do
AX = Plugin.Sys.GetScRX():AY = Plugin.Sys.GetScRY()
FindPic 0, 0, AX, AY, "Attachment:\立刻购买.bmp", 0.9, intX, intY
If intX > 0 And intY > 0 Then
MoveTo intX+5,intY+5
LeftClick 1
Do
FindPic 0, 0, AX, AY, "Attachment:\立即支付.bmp", 0.9, intX1, intY1
If intX1 > 0 And intY1 > 0 Then
MoveTo intX1+5,intY1+5
LeftClick 1
Exit Do
End If
Loop
End If
Loop
复制上面代码可达成
注意事项:用按键精灵抓抓功能抓取相应图片放到脚本的附件内

Ⅱ 按键精灵怎样做连连看脚本

Dim se(19, 11)
UserVar llk=0 "消除时间"
e = Plugin.Window.Find(0, "QQ游戏 - 连连看角色版")
f = Plugin.window.Foreground()
g = Plugin.Sys.GetScRX()
h = Plugin.Sys.GetScRY()
If e > 0 Then
If f = e Then
i = Plugin.Window.GetWindowRect(e)
j = Split(i, "|")
k = Int(j(0))
l = Int(j(1))
bj="无"
If k >= 0 and l >= 0 and k + 799 <= g and y + 599 <= h Then
rect=GetPixelColor(664+k,96+l)
IfColor k + 64, l + 80, rect, 1 Then
k = k + 28
l = l + 195
m = 0
n = 1
For a = 0 To 18
For b = 0 To 10
se(a, b) = bj
IfColor a * 31 - 12 + k, b * 35 - 13 + l, rect, 0 Then
se(a, b) = GetPixelColor(a * 31 + k, b * 35 + l)
m = m + 1
End If
Next
Next
While m <> 0 and n <> m
n = m
For a = 0 To 18
For b = 0 To 10
If se(a, b) <> bj Then
d=b+1
For c = a To 18
While d <= 10
If se(a, b) = se(c, d) Then
If a = c Then
y1 = b + 1
While se(a, y1) = bj
y1=y1+1
Wend
If y1 = d Then
Call 消除():b=d
Exit For
Else
y2=1
While se(a + y2, b) = bj and se(c + y2, d) = bj
y1 = b + 1
While se(a+y2, y1) = bj
y1=y1+1
Wend
If y1 >= d Then
Call 消除():b=d
Exit For
End If
y2=y2+1
Wend
y2=1
While se(a - y2, b) = bj and se(c - y2, d) = bj
y1 = b + 1
While se(a-y2, y1) = bj
y1=y1+1
Wend
If y1 >= d Then
Call 消除():b=d
Exit For
End If
y2=y2+1
Wend
End If
ElseIf b = d Then
x1 = a + 1
While se(x1, b) = bj
x1=x1+1
Wend
If x1 = c Then
Call 消除()
Exit For
Else
x2=1
While se(a, b + x2) = bj and se(c, d + x2) = bj
x1 = a + 1
While se(x1, b+x2) = bj
x1=x1+1
Wend
If x1 >= c Then
Call 消除()
Exit For
End If
x2=x2+1
Wend
x2=1
While se(a, b - x2) = bj and se(c, d - x2) = bj
x1 = a + 1
While se(x1, b-x2) = bj
x1=x1+1
Wend
If x1 >= c Then
Call 消除()
Exit For
End If
x2=x2+1
Wend
End If
Else
left2=c:down1=b:up1=b
While se(a,down1-1)=bj
down1=down1-1
Wend
While se(a, up1 + 1) = bj
up1=up1+1
Wend
While se(left2 - 1, d) = bj
left2=left2-1
Wend
If down1<=d and up1>=d and left2<=a Then
Call 消除():b=up1
Exit For
End If
right1=a:down2=d:up2=d
While se(right1+1, b) = bj
right1=right1+1
Wend
While se(c, down2 - 1) = bj
down2=down2-1
Wend
While se(c, up2 + 1) = bj
up2=up2+1
Wend
If up2 >= b and down2 <= b and right1 >= c Then
Call 消除():b=up1
Exit For
End If
left1=a:right2=c:bigy=d:smally=b
While se(left1 - 1, b) = bj
left1=left1-1
Wend
While se(right2 + 1, d) = bj
right2=right2+1
Wend
If b > d Then
bigy=b
smally=d
End If
If left1 < left2 Then
leftz=left2
Else
leftz=left1
End If
If right1 < right2 Then
lefty=right1
Else
lefty=right2
End If
w=0
While w<lefty-leftz+1
y1=smally
While se(leftz+w,y1+1)=bj
y1=y1+1
Wend
If y1 >= bigy Then
Call 消除():b=up1
Exit For
End If
w=w+1
Wend
If down1 < down2 Then
leftx=down2
Else
leftx=down1
End If
If up1 < up2 Then
leftw=up1
Else
leftw=up2
End If
w=0
While w<leftw-leftx+1
x1=a
While se(x1+1,leftx+w)=bj
x1=x1+1
Wend
If x1 >= c Then
Call 消除():b=up1
Exit For
End If
w=w+1
Wend
d=up2
End If
End If
d=d+1
Wend
d=0
Next
End If
Next
Next
Wend
LeftUp 1
End If
End If
End If
End If
Sub 消除()
MoveTo a * 31 + k, b * 35 + l
LeftDown 1
Delay llk
MoveTo c * 31 + k, d * 35 + l
LeftDown 1
se(a, b) = bj
se(c, d) = bj
m = m - 2
End Sub

Ⅲ 帮我弄一个按键精灵的自动拾取脚本

Dim screenwidth,screenheight
screenwidth=Plugin.Sys.GetScRX
screenheight = Plugin.Sys.GetScRY
Do
FindPic 0,0,screenwidth,screenheight,"Attachment:\你的图片.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
Delay 100
MoveTo intX, intY
Delay 100
LeftClick
Call Plugin.Msg.Tips("""自动拾取完成")
End If

Loop

颜色不靠谱 还是找图好一些

Ⅳ 按键精灵抓一个图鼠标点10下然后再抓下一个图按键点10下然后结束怎么编这个脚本啊。。。在线等

复制以下内容根据实际需要调整延迟时间及循环次数
Rem 标记1
FindPic 251,350,334,580,"Attachment:\hh.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX, intY
//下面语句会执行十遍 可根据实际需要自行设定延迟时间1000毫秒=1秒
For 10
LeftClick 1
Delay 1000
Next
//下面双击命令未说明用途暂注释掉 如需要请删除语句前的//
//LeftDoubleClick 1
Else
//如果没找到图片hh.bmp就跳转到标记1处
Goto 标记1
End if
Rem 标记2
FindPic 251,350,334,580,"Attachment:\hhh.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX, intY
For 10
LeftClick 1
Delay 1000
Next
Else
Goto 标记2
End If
//如果没有其他循环并且脚本设置执行1次的话,找到图片hh.bmp点击十次找到图片hhh.bmp点击十次,会执行到这里程序结束。

Ⅳ 求按键精灵自动识别图片的脚本

plugin.simplugocr.reg("")
//精灵里随便一句命令以注册com插件
dim s
//声明变量 s
set aa=CreateObject("simplugocr.ocr")
aa.fontcolor="000000"
s=aa.findstrsByFont("宋体",9,"你想要识别的文字1$你想要识别的文字2$你想要识别的文字3",1,1,1440,900,9)
//("宋体",9,"你图片的文字类型和大小,1,1,1440,900 是坐标范围根据自己的修改可以达到更快的速度
msgbox s
//弹出识别到的字,根据自己需要修改
插件下载地址http://bbs.vrbrothers.com/viewthread.php?tid=127985&highlight=
如果不能识别或不会使用最好能吧图发上来,因为要做字库,或者可以到http://bbs.vrbrothers.com官网上去看教程,希望满意!

Ⅵ 按键精灵 语法错误:脚本 我的脚本1 ,第28行,第1个字符:(错误码0)缺少符号。怎么解决啊

Loop改为Next,语法就没错误了,不过你写程序的习惯不好,程序尽量不要用Goto,程序员的要求,是不能用Goto的,因为滥用Goto,程序结构会变得混乱,一旦代码有逻辑问题,会非常麻烦,建议你先学习按键精灵语言语法。

Ⅶ 按键精灵连续找图点击求脚本

Rem a1
X = Plugin.Sys.GetScRX()
Y = Plugin.Sys.GetScRY()
Rem a2
FindPic 0,0,X,Y,"Attachment:\多人混战.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX + 2, intY + 2
Delay 100
LeftClick 1
Delay 100
MoveTo intX, 0
Delay 100
Else
Goto a2
End If
Rem a3
FindPic 0,0,X,Y,"Attachment:\下一步.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX + 2, intY + 2
Delay 100
LeftClick 1
Delay 100
MoveTo intX, 0
Delay 100
Else
Goto a3
End If
Rem a4
FindPic 0,0,X,Y,"Attachment:\确定.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX + 2, intY + 2
Delay 100
LeftClick 1
Delay 100
MoveTo intX, 0
Delay 100
Else
Goto a4
End If
Rem a5
FindPic 0,0,X,Y,"Attachment:\退出.bmp",0.9,intX,intY
If intX > 0 And intY > 0 Then
MoveTo intX + 2, intY + 2
Delay 100
LeftClick 1
Delay 100
MoveTo intX, 0
Delay 100
Else
Goto a5
End If
Goto a1
自己截图,然后命名好后,添加到附件里

Ⅷ 按键精灵,如何满足在某个条件后,再进行下一步脚本运行

//图片"打印.bmp"添加到附件中就可以了,图片尽量小点.屏幕中是唯一就行了.
图片目录
=
"Attachment:\"
X0
=
0
:
Y0
=
0
窗口宽度
=
Plugin.Sys.GetScRX()
:
窗口高度
=
Plugin.Sys.GetScRY()
Delay
500
Do
Delay
1000
FindPic
X0,
Y0,
窗口宽度,
窗口高度,
图片目录
&"打印.bmp",
1,
X,
Y
If
X
>
0
And
Y
>
0
Then
MoveTo
x,
y
LeftClick
1
End
If
Loop
Until
x
>
0
or
Y
>
0

Ⅸ 按键精灵做得脚本怎么样可以在别的电脑上都可以使用 毕竟显示器都不一样

  1. 你做一个多做几个常用分辨率的版本,如1024*768和1440*900,脚本自己选择

  2. 运行脚本就强制电脑分辨率改变成脚本适用分辨率。

    例如:


    ScreenX = Plugin.Sys.GetScRX()

    ScreenY = Plugin.Sys.GetScRY()

    Dev = Plugin.Sys.GetScDep()

    If ScreenX = 1440 and ScreenY = 900 Then

    //运行1440*900脚本

    ElseIf ScreenX = 1024 and ScreenY = 768Then

    //运行1024*768脚本

    Else

    If abs(ScreenX - 1024) > abs(ScreenX - 1440) Then //如果接近1440,就改变分辨率为1440*900

    //改为1440*900

    Call Plugin.Sys.SetSc(1440,900,32)

    Else

    //否则改为1024*900

    Call Plugin.Sys.SetSc(1024,768,32)

    End If

    End If

Ⅹ 关于按键精灵脚本的类型不匹配问题

Hwnd = Plugin.Window.Find(0,)
sRect = Plugin.Window.GetClientRect(Hwnd)
Dim MyArray
MyArry=Split(Rect, ) // 改为sRect
Ux=CLng(MyArray(0))
Uy=CLng(MyArray(1))
Goto xuanxe
KeyPress `, 1
Delay 1000
IfColor 374+ux,61+uy,11CC,0 Then
KeyPress 1, 1
Else
Rem xuanxe
End If