Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function moveForward()
- while not turtle.forward() do
- print("Stuck, retrying")
- sleep(1)
- end
- end
- function moveUp()
- while not turtle.up() do
- print("Stuck, retrying")
- sleep(1)
- end
- end
- function placeSlot(x)
- turtle.select(x)
- turtle.placeDown()
- end
- function clearDirt()
- turtle.select(16)
- turtle.digDown()
- end
- function deploy()
- for i = 2,4 do
- moveForward()
- clearDirt()
- placeSlot(1)
- placeSlot(i)
- end
- end
- function moveToPlace()
- turtle.turnLeft()
- turtle.turnLeft()
- turtle.select(16)
- turtle.digUp()
- for i = 1,2 do
- moveUp()
- turtle.placeDown()
- end
- end
- function goHome()
- turtle.turnLeft()
- turtle.turnLeft()
- for i = 1,3 do
- moveForward()
- end
- turtle.select(16)
- for i = 1,2 do
- turtle.digDown()
- turtle.down()
- end
- turtle.placeUp()
- end
- moveToPlace()
- deploy()
- goHome()
Advertisement
Add Comment
Please, Sign In to add comment