a = getColor(1034, 932);--這裡判斷體力不夠時幫你補充 座標可能每支手機不同,設定方式我在體力剩1X-2X那邊位子是黃色的旁邊灰色空白地方點一下,他只要判斷到那邊是灰色的 代表體力不足要幫你補充
if a == 0x424d5a then
mSleep(500);
touchDown(0, 1020, 70); --遊俠有一個圖示這個我不用圖片搜索的方式 因為直接用座標點擊會更有效率 那麼就改成你手機的座標,我通常習慣放在最左上
touchUp(0);
mSleep(500);
touchDown(0, 465, 794); --這是第二個步驟遊俠第二個選項點進"已有任務"
touchUp(0);
return aaa()
else
return bb()
end
end
function aaa()
mSleep(500);
x, y = findImageFuzzy("/storage/emulated/0/Touchelper/plugins/任務2.bmp",70);--這個任務二代表你體力無限的代碼在你遊俠任務裡是任務2,如果沒變動就不需要改
if x ~= -1 and y ~= -1 then
click(x, y)
return aaaa()
else
x, y = findImageFuzzy("/storage/emulated/0/Touchelper/plugins/任務2.bmp",70);
if x ~= -1 and y ~= -1 then
click(x, y)
return aaaa()
else
x, y = findImageFuzzy("/storage/emulated/0/Touchelper/plugins/任務2.bmp",70);
if x ~= -1 and y ~= -1 then
click(x, y)
return aaaa()
end
end
end
end
function aab()
mSleep(500)
x, y = findImageFuzzy("/storage/emulated/0/Touchelper/plugins/返回.bmp",80);
if x ~= -1 and y ~= -1 then
click(x, y)
return bb()
else
return bb()
end
end