Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local blocks = {"cobblestone","dirt","cobbled_deepslate"}
- local data = turtle.getItemDetail()
- while true do
- local event = os.pullEvent(turtle_inventory)
- os.sleep(20)
- for i = 1, 16 do
- if turtle.getItemCount(i) > 0 then
- turtle.select(i)
- data = turtle.getItemDetail()
- for i = 1,#blocks do
- if (string.sub(data.name,11)) == blocks[i] then
- turtle.drop()
- break
- end
- end
- end
- if turtle.getItemCount(i) > 0 then
- turtle.dropDown()
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement