Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- 0yCVbCCH
- -- slots: seeds, fuel, detector, filter, breaker
- local plotLength = 16
- local function harvestPlant()
- turtle.select(5)
- turtle.placeDown()
- turtle.select(6)
- repeat until turtle.forward()
- repeat until turtle.down()
- sleep(2)
- repeat until turtle.up()
- repeat until turtle.back()
- turtle.select(5)
- turtle.digDown()
- turtle.select(1)
- repeat until turtle.back()
- turtle.placeDown()
- repeat until turtle.forward()
- end
- local function testPlant()
- turtle.turnRight()
- turtle.select(3)
- turtle.placeDown()
- sleep(0)
- turtle.select(4)
- turtle.dropDown()
- sleep(0)
- local isGrown = rs.getInput("bottom")
- turtle.select(4)
- turtle.suckDown()
- turtle.select(3)
- turtle.digDown()
- turtle.select(1)
- sleep(0)
- if isGrown then harvestPlant() end
- turtle.turnLeft()
- end
- turtle.turnRight()
- while turtle.getItemCount(1) ~= 0 do
- while turtle.getFuelLevel() < 64 do
- while turtle.getItemCount(2) < 2 do
- print("Out of Fuel")
- sleep(1)
- end
- turtle.select(2)
- turtle.refuel(turtle.getItemCount(2) - 1)
- turtle.select(1)
- end
- for x = 1, plotLength do
- testPlant()
- if x ~= plotLength then
- repeat until turtle.forward()
- end
- end
- turtle.turnRight()
- repeat until turtle.forward()
- turtle.turnRight()
- for x = 1, plotLength do
- testPlant()
- if x ~= plotLength then
- repeat until turtle.forward()
- end
- end
- turtle.turnRight()
- repeat until turtle.forward()
- turtle.turnRight()
- end
Advertisement
Add Comment
Please, Sign In to add comment