按键精灵安卓的循环与跳出循环或停止循环
我刚接触按键没几天是个新手,这几天琢磨做个小脚本,现在出现个问题之前写的都在无限循环里面,可是我想加个条件后跳出循环,条件有了就是不会加进去,请路过的老司机顺手帮我解决下...
我刚接触按键没几天是个新手,这几天琢磨做个小脚本,现在出现个问题之前写的都在无限循环里面,可是我想加个条件后跳出循环,条件有了就是不会加进去,请路过的老司机顺手帮我解决下这个问题,跪谢!!!!
Dim intX,intY,inta,intb
Do
FindMultiColor 0,0,0,0,"1BDE14-101010","-8|-1|0B8A13-101010,-15|1|105F1B-101010",0,0.9,intX,intY
If intX > -1 And intY > -1 Then
Tap 66, 504
Delay 1000
Else
Tap 61, 690
Delay 1000
End If
Loop
下面是要加的条件,是多点比色出来的代码,希望在循环中如果出现这多点比色的情况后跳出循环或循环结束。求老司机帮忙解决下。跪谢了!!
FindMultiColor 471,537,365,658,"0FAAD8-101010","0|14|184653-101010,0|21|0FB9EB-101010,0|32|138DB1-101010,1|56|0FB6E7-101010,1|66|0FB5E5-101010",0,0.9,inta,intb
If inta > -1 And intb > -1 Then
End If 展开
Dim intX,intY,inta,intb
Do
FindMultiColor 0,0,0,0,"1BDE14-101010","-8|-1|0B8A13-101010,-15|1|105F1B-101010",0,0.9,intX,intY
If intX > -1 And intY > -1 Then
Tap 66, 504
Delay 1000
Else
Tap 61, 690
Delay 1000
End If
Loop
下面是要加的条件,是多点比色出来的代码,希望在循环中如果出现这多点比色的情况后跳出循环或循环结束。求老司机帮忙解决下。跪谢了!!
FindMultiColor 471,537,365,658,"0FAAD8-101010","0|14|184653-101010,0|21|0FB9EB-101010,0|32|138DB1-101010,1|56|0FB6E7-101010,1|66|0FB5E5-101010",0,0.9,inta,intb
If inta > -1 And intb > -1 Then
End If 展开
1个回答
展开全部
Dim intX,intY,inta,intb
Do
FindMultiColor 0,0,0,0,"1BDE14-101010","-8|-1|0B8A13-101010,-15|1|105F1B-101010",0,0.9,intX,intY
If intX > -1 And intY > -1 Then
Tap 66, 504
Delay 1000
Else
Tap 61, 690
Delay 1000
End If
FindMultiColor 471,537,365,658,"0FAAD8-101010","0|14|184653-101010,0|21|0FB9EB-101010,0|32|138DB1-101010,1|56|0FB6E7-101010,1|66|0FB5E5-101010",0,0.9,inta,intb
If inta > - 1 And intb > - 1 Then
Exit Do
End If
Loop
语句结构就是这样 可以退出循环 但是我调试的时候有几个提示是类型不匹配这个问题你自己找吧
Do
FindMultiColor 0,0,0,0,"1BDE14-101010","-8|-1|0B8A13-101010,-15|1|105F1B-101010",0,0.9,intX,intY
If intX > -1 And intY > -1 Then
Tap 66, 504
Delay 1000
Else
Tap 61, 690
Delay 1000
End If
FindMultiColor 471,537,365,658,"0FAAD8-101010","0|14|184653-101010,0|21|0FB9EB-101010,0|32|138DB1-101010,1|56|0FB6E7-101010,1|66|0FB5E5-101010",0,0.9,inta,intb
If inta > - 1 And intb > - 1 Then
Exit Do
End If
Loop
语句结构就是这样 可以退出循环 但是我调试的时候有几个提示是类型不匹配这个问题你自己找吧
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询