Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function harvest()
- turtle.dig()
- turtle.forward()
- for i = 1, 6 do
- turtle.digUp()
- turtle.up()
- end
- end
- local function goDown()
- while turtle.detectDown() == false do
- turtle.down()
- end
- end
- local function plant()
- turtle.up()
- for i = 1, 6 do
- turtle.select(1)
- turtle.placeDown()
- turtle.back()
- end
- end
- local function checkFuel()
- if turtle.getFuelLevel() <= 200 then
- turtle.select(16)
- turtle.refuel(16)
- turtle.select(1)
- end
- end
- local function itemsOut()
- for i = 2, 15 do
- turtle.select(i)
- turtle.dropDown()
- end
- turtle.select(1)
- end
- while true do
- if turtle.detect() == true then
- checkFuel()
- for i = 1, 6 do
- harvest()
- goDown()
- end
- plant()
- turtle.down()
- itemsOut()
- sleep(1800)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement