Advertisement
rhn

Endoflame

rhn
Apr 25th, 2020
687
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.63 KB | None | 0 0
  1. inv=peripheral.wrap("top")
  2.  
  3. for i=1,16 do
  4.     turtle.select(i)
  5.     turtle.dropDown()
  6. end
  7.  
  8. while true do
  9.     for i=1,inv.size() do
  10.         slotmeta=inv.getItemMeta(i)
  11.         if slotmeta~=nil and (slotmeta.name=="tcomplement:storage" or slotmeta.name=="minecraft:coal_block") then
  12.                 inv.pushItems("down",i,1,1)
  13.                 break
  14.         end
  15.     end
  16.     turtle.select(1)
  17.     if turtle.getItemCount(1)>0 then
  18.         turtle.craft()
  19.         sleep(0.5)
  20.         while turtle.getItemCount(1)>0 do
  21.             if redstone.getInput("bottom")==false then
  22.                 turtle.dropDown(1)
  23.                 sleep(0.5)
  24.             else
  25.                 sleep(1)
  26.             end
  27.         end
  28.     else
  29.         sleep(5)
  30.     end
  31. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement