Guest User

Untitled

a guest
May 19th, 2013
21
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function select()
  2. while not turtle.select(slot) do
  3. slot = slot + 1
  4. end
  5. end
  6.  
  7. function placeDown()
  8. select()
  9. turtle.placeDown()
  10. end
  11.  
  12. function move()
  13. if forward () then
  14. turtle.forward()
  15. posX = posX + 1
  16. end
  17.  
  18. if backward () then
  19. turtle.backward()
  20. posX = posX - 1
  21. end
  22.  
  23. end
  24.  
  25. function newline()
  26. turtle.left()
  27. turtle.forward()
  28. turtle.right()
  29.  
  30. if forward () then
  31. forward = false
  32. backward = true
  33. end
  34.  
  35. if backward () then
  36. forward = ture
  37. backeward = false
  38. end
  39.  
  40. end
  41.  
  42. slot = 2
  43. forward = true
  44. blockcount = 0
  45.  
  46. print("Starting to work")
  47. turtle.select(1)
  48.  
  49. if turtle.refuel() then
  50.  
  51. turtle.forward()
  52. turtle.turnRight()
  53.  
  54. for posZ = 0, 22, 1 do
  55.  
  56. for posY = 0, 22, 1 do
  57. blockcount = blockcount + 1
  58. if blockcount not 5 then
  59. placeDown()
  60. end
  61. if blockcount 5  then
  62. blockcount = 0
  63. end
  64.  
  65. move()
  66. end
  67.  
  68. newline()
  69.  
  70. end
  71.  
  72. end
  73.  
  74. else do
  75. print ("Please fill in fuel in slot 1, 528 movement required")
  76. end
Advertisement
Add Comment
Please, Sign In to add comment