Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- canChest = peripheral.wrap("left")
- oxComp = {{p = peripheral.wrap("front"),d = "south"},{p = peripheral.wrap("top"),d = "down"}}
- function getCan()
- local found = 0
- while found == 0 do
- canChest.condenseItems()
- found = canChest.pushItem("east",1,1)
- end
- end
- function startUp()
- local item = turtle.getItemDetail()
- if item ~= nil then
- if item.damage > 0 then
- if oxComp[1].getStackInSlot(1) == nil then
- turtle.drop()
- end
- if oxComp[2].getStackInSlot(1) == nil then
- turtle.dropUp()
- end
- end
- end
- if oxComp[1].p.getStackInSlot(1) == nil then
- getCan()
- turtle.drop()
- end
- if oxComp[2].p.getStackInSlot(1) == nil then
- getCan()
- turtle.dropUp()
- end
- turtle.dropDown()
- end
- turtle.select(1)
- startUp()
- while true do
- if turtle.suck() == true then
- while turtle.dropDown() == false do
- print("OutPut chest problem")
- sleep(0.5)
- end
- getCan()
- while turtle.drop() == false do
- print("frontal bloackage")
- sleep(0.5)
- end
- end
- if turtle.suckUp() == true then
- while turtle.dropDown() == false do
- print("OutPut chest problem")
- sleep(0.5)
- end
- getCan()
- while turtle.dropUp() == false do
- print("frontal bloackage")
- sleep(0.5)
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement