Daxturus

Fragile Fluid Shard Caching Turtle Code

Jun 15th, 2021 (edited)
191
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.72 KB | None | 0 0
  1. local tank = peripheral.wrap("top")
  2. while true do
  3.     if tank.getMetadata().tanks[1].capacity <= tank.getMetadata().tanks[1].amount then
  4.         turtle.digUp()
  5.         for i = 1, 16 do
  6.             turtle.suckUp()
  7.         end
  8.         found = false
  9.         while found == false do
  10.             for i = 1, 16 do
  11.                 turtle.select(i)
  12.                 if turtle.getItemCount() > 0 then
  13.                     if turtle.getItemDetail().name == "buildcraftfactory:tank" then
  14.                         turtle.placeUp()
  15.                         found = true
  16.                     end
  17.                     turtle.drop()
  18.                 end
  19.             end
  20.         end
  21.         for i = 1, 16 do
  22.             turtle.select(i)
  23.             if turtle.getItemCount() > 0 then
  24.                 if turtle.getItemDetail().name == "buildcraftfactory:tank" then
  25.                     turtle.placeUp()
  26.                 else
  27.                     turtle.drop()
  28.                 end
  29.             end
  30.         end
  31.     end
  32. end
  33.    
Add Comment
Please, Sign In to add comment