Android 台灣中文網

標題: 幫看腳本哪裏錯呢。 [打印本頁]

作者: iopecc    時間: 2014-1-24 16:02
標題: 幫看腳本哪裏錯呢。
本帖最後由 iopecc 於 2014-1-25 21:04 編輯


-- 適用螢幕參數
SCREEN_RESOLUTION="1920x1080";
SCREEN_COLOR_BITS=32;



function main()
a= getColor(829, 1777);   ------抛竿
b=getColor(1062, 1864);----起钓
c=getColor(252, 1444);----卖出
d=getColor(93, 1511);----继续

if a==1061119 then
mSleep(5000);
touchDown(308, 1589);
mSleep(500)
touchUp(0);

else



if b==2188643 then
mSleep(5000);
touchDown(308, 1589);
mSleep(500)
touchUp(0);
else



if c==1604054 then
mSleep(5000);
touchDown(277, 1477);
mSleep(500)
touchUp(0);
else

if d==15165712 then
mSleep(5000);
touchDown(277, 1477);
mSleep(500)
touchUp(0);
else
end
end
end
end
end
作者: luluhuhu    時間: 2014-1-25 05:46
每一個mSleep(50)都少了;
全部加上去.再試試
作者: lori3.31    時間: 2014-1-25 19:45
function main要有一個 (end) 當結尾而每給 (if) 都要有一個 (end) 配成一組程序
因為你有一個 (function main)、 四個 (if)
所以你總共要有五個 (end)
作者: iopecc    時間: 2014-1-25 21:05
lori3.31 發表於 2014-1-25 19:45
function main要有一個 (end) 當結尾而每給 (if) 都要有一個 (end) 配成一組程序
因為你有一個 (function m ...

改了也沒動作,而且手機卡頓卡頓的
作者: lori3.31    時間: 2014-1-25 22:36
function main()
a= getColor(829, 1777);
b=getColor(1062, 1864);
c=getColor(252, 1444);
d=getColor(93, 1511);

if a == 1061119 then
mSleep(5000);
touchDown(308, 1589);
mSleep(500);
touchUp(0);
else

end

if b == 2188643 then
mSleep(5000);
touchDown(308, 1589);
mSleep(500);
touchUp(0);
else

end

if c == 1604054 then
mSleep(5000);
touchDown(277, 1477);
mSleep(500);
touchUp(0);
else

end

if d == 15165712 then
mSleep(5000);
touchDown(277, 1477);
mSleep(500);
touchUp(0);
else

end
end

這樣看可不可以
還有顏色代碼應該是要0x??????
例如藍色是 0x45bae7
前面是 零x 後面是六碼的小寫英文或數字




歡迎光臨 Android 台灣中文網 (https://apk.tw/) Powered by Discuz! X3.1