它的是明碼的腳本
喀石函數錯誤 因為我沒有實際使用
但你可以嘗試自己改看看
- createWindow("ChangeSet2")
- createTextViewEx("ChangeSet2","start17","嗑石狂刷:")
- createRadioBoxEx("ChangeSet2","eat1","否",true)
- createRadioBoxEx("ChangeSet2","eat1","是",false)
複製代碼
- --判定吃石回體
- screencap()
- local color1 = getColor(136*r+xr,575*r+yr)
- local color2 = getColor(156*r+xr,575*r+yr)
- local flag1,x,y = findColorFuzzy(color1,90,300*r+xr,565*r+yr,340*r+xr,585*r+yr)
- local flag2,x,y = findColorFuzzy(color2,90,300*r+xr,565*r+yr,340*r+xr,585*r+yr)
- local flag3,x,y = findColorFuzzy(color1,90,370*r+xr,565*r+yr,390*r+xr,585*r+yr)
- local flag4,x,y = findColorFuzzy(color2,90,370*r+xr,565*r+yr,390*r+xr,585*r+yr)
- local flag5,x,y = findColorFuzzy(color1,90,420*r+xr,565*r+yr,440*r+xr,585*r+yr)
- local flag6,x,y = findColorFuzzy(color2,90,420*r+xr,565*r+yr,440*r+xr,585*r+yr)
- flagB=flag1 or flag2
- flagC=flag3 or flag4
- flagD=flag5 or flag6
- if flagB==false and flagC==true and flagD==true then
- if eat1=="否" then
- log("執行中斷:沒體力了")
- toast("執行中斷:沒體力了")
- exit()
- else
- sleep(1000);
- touchClick(205*r+xr, 570*r+yr)
- sleep(10000);
- touchClick(535*r+xr,560*r+yr)
- log("體力已恢復")
- toast("體力已恢復")
- end
- elseif flagB==false and flagC==false and flagD==true then
- toast("選取重試")
- elseif flagB==true and flagC==true and flagD==true then
- toast("載入中")
- else
- toast("偵測吃石函數錯誤")
- log("偵測吃石函數錯誤")
- end
- repeat
- sleep(2000+sec)
複製代碼 |