Advertisement
Guest User

farming

a guest
Feb 18th, 2019
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.47 KB | None | 0 0
  1. width=9
  2. length=8
  3.  
  4.  
  5. function turnLeft()
  6.     turtle.turnLeft()
  7.     turtle.forward()
  8.     turtle.turnLeft()
  9. end
  10.  
  11. function turnRight()
  12.     turtle.turnRight()
  13.     turtle.forward()
  14.     turtle.turnRight()
  15. end    
  16.  
  17. left=true
  18. for y = 0, width, 1 do
  19.     for x = 0, length, 1 do
  20.         turtle.forward()
  21.     end
  22.     if(left) then turnLeft() end
  23.     if(left == false) then turnRight() end
  24.     if(left) then
  25.         left = false
  26.     else
  27.         left = true
  28.     end
  29. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement