Advertisement
Guest User

Untitled

a guest
Jan 18th, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. local DIRECTION_FROM_TRANSPOSER_TO_COMPUTER = "north"
  2. local SIDE_OF_COMPUTER_TOUCHING_TRANSPOSER = "left"
  3. local SIDE_OF_COMPUTER_TOUCHING_CHEST = "back"
  4.  
  5. local waterSource = peripheral.wrap(SIDE_OF_COMPUTER_TOUCHING_TRANSPOSER)
  6. local chest = peripheral.wrap(SIDE_OF_COMPUTER_TOUCHING_CHEST)
  7.  
  8. function getFullCompName()
  9. return os.getComputerLabel()..","..tostring( os.getComputerID() )
  10. end
  11.  
  12.  
  13.  
  14. function run()
  15. print(getFullCompName())
  16. print("running(ctrl-T)...")
  17. local done = false
  18. while not done do
  19.  
  20.  
  21. for i = 1, 15 do -- assumes slot 16 is for suckDown() to recive resultant flower
  22. turtle.select( i )
  23. local didDrop = turtle.dropDown( 1 )
  24. if not didDrop then
  25. if i == 1 then done = true end
  26. break
  27. end
  28. os.sleep( 2 )
  29. end
  30.  
  31. --pick up finished flower
  32. turtle.select(16)
  33. turtle.suckDown()
  34. os.sleep(2) --autonomus activator and fluid transposer do thier work while turtle is droping but 2 seconds extra wont hurt
  35. end
  36. print("done")
  37. end
  38.  
  39. run()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement