function 幸运抽奖()color = {83,567,109,592,"88,574,#FFFFFF|100,583,#7D711EE",95};p = findColor(color);if p thenprint('点击了关闭幸运抽奖')click(632,352); sleep(2000)end
end
function 关闭PK()color = {314,740,416,769,"331,753,#479FFA|393,753,#F81554E",95};p = findColor(color);if p thenprint('点击了关闭PK')click(605,453); sleep(2000)end
end
function 点击红包()for i=0,30,1 docolor = {43,220,670,1169,"273,289,#FB3F18",100};local p = findColor(color);if p thenc=c+1print('点击了红包'..c)click(p.x+5,p.y+5); sleep(500)elsebreakendendprint("...")
end
print("start")
c=0
while true dosleep(500)幸运抽奖()关闭PK()点击红包()
end
print("the end")