hunter3216

aquamarinePlacerBasic.lua

Mar 17th, 2023 (edited)
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.94 KB | None | 0 0
  1. -- shell.run("rm loadAPIs.lua") shell.run("pastebin get 6x0B3PVu loadAPIs.lua") shell.run("loadAPIs.lua") shell.run("rm aquamarinePlacer.lua") shell.run("pastebin get hUUnD8Zi aquamarinePlacer.lua") shell.run("aquamarinePlacer.lua")
  2.  
  3.  
  4. robot.init()
  5. robot.initAutomata()
  6.  
  7. flag, block = turtle.inspect()
  8. while block.name ~= "astralsorcery:well" do
  9. turtle.turnLeft()
  10. flag, block = turtle.inspect()
  11. end
  12.  
  13. function getItemSlot()
  14. turtle.select(1)
  15. while turtle.getItemCount() == 0 and turtle.getSelectedSlot() ~= 16 do
  16. turtle.select(turtle.getSelectedSlot() + 1)
  17. end
  18. end
  19. well = peripheral.wrap("front")
  20. os.sleep(8)
  21. while true do
  22. if turtle.getFuelLevel() < 80 then
  23. turtle.select(16)
  24. turtle.refuel()
  25. turtle.select(1)
  26. end
  27. wellCur = well.tanks()
  28. wellItems = well.list()
  29.  
  30. if wellItems[1] == nil then
  31. getItemSlot()
  32. robot.useOnBlock()
  33. end
  34.  
  35. end
Advertisement
Add Comment
Please, Sign In to add comment