苍穹战线练级脚本v.1 发表于 2018-05-04 | 分类于 计算机技术 字数统计: 8.5k 嘛,工作上的事没找到没找到什么思路,所以摸了会儿鱼,把前阵子一直想弄的苍穹战线练级脚本写了下。 这次就不放什么流程图之类的了,功能比较简单,就只是练级而已。代码扔下面了。 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596Delay 2000Dim screenX,screenY,deviceID,first=1screenX = GetScreenX()screenY = GetScreenY()deviceID = GetDeviceID()TracePrint ""&screenX&"*"&screenY&chr(10)While 1 TracePrint "准备进入战役" Call zhanyi() first = 2 Delay 3000Wend//----------------//Sub zhanyi() Dim dijiguan=6,zdd=1,zhengxin,yanboss1,ty=245,zyi=0 //zyi的值影响章节,1为第2章。dijiguan的值影响关卡// Touch 213, 1433, 100 TracePrint "点击战役" Delay 1000 Touch 226, 141, 100 TracePrint "关卡类型选择,选主线战役" Delay 1000 ty=ty+zyi*355 Touch 99, ty, 100 TracePrint "章节选择" Delay 1000 If first = 1 Then TracePrint "第一次启动" For 7 TouchDown 634, 608, 1 TouchMove 608,1177, 1, 400 TouchUp 1 TracePrint "归零" Delay 1000 Next For dijiguan TouchDown 608,1177, 1 TouchMove 634,608, 1, 400 TouchUp 1 TracePrint "向左滑动6次" Delay 1000 Next End If Delay 1000 Touch 660, 947, 100 TracePrint "进入关卡" Delay 1000 Touch 911, 832, 100 TracePrint "确认队伍,一队" Delay 1000 Touch 96, 1792, 100 TracePrint "确认出击" Delay 3000 While zdd zdd = CmpColor(1066,103, "14E6BC", 0.9) If zdd > -1 Then TracePrint "寻找前进并找到了" zdd = 1 Touch 70, 1756, 100 TracePrint "点击前进" Delay 28000 Touch 940, 1546, 100 TracePrint "点击阵型" Delay 1000 Else TracePrint"寻找前进,没有找到" Touch 620, 807, 100 TracePrint "尝试点决战" Delay 3000 yanboss1 = CmpColor(838, 1620, "FFF72A", 0.9) If yanboss1 > -1 Then TracePrint "没有前进且发现结束页面" Touch 115, 1238, 100 TracePrint "结束关卡内循环,回到外界面" Delay 2000 Exit While End If End If Delay 1000 Wend End Sub -------------本文结束感谢您的阅读-------------