Advertisement
Kengu

Untitled

Dec 10th, 2019
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. run = false
  2. print("**Farming area is meant to be a rectangle**")
  3. print("**Turtle should start at the bottom left of the farm plot behind first crop**")
  4.  
  5. io.write("What is the crop type: ")
  6. croptype = (tostring(io.read()))
  7. io.write("How many blocks forward: ")
  8. blocksforward = (tonumber(io.read()))
  9. io.write("How many blocks to the right: ")
  10. blocksright = (tonumber(io.read()))
  11. x = 0
  12. y = 0
  13.  
  14. if croptype == "hemp" then
  15. run = true
  16. else
  17. print("INVALID")
  18. end
  19. while run do
  20. if turtle.detect() then
  21. if x < blocksforward then
  22. turtle.dig()
  23. turtle.forward()
  24. x = x + 1
  25. else
  26. print("error")
  27. end
  28.  
  29.  
  30.  
  31. end
  32. end
  33. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement