Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local apiary = peripheral.wrap("right")
- local chest = peripheral.wrap("top")
- local function resetApiary()
- local outputs = apiary.getAllStacks()
- for slot = 3, 9 do
- local output = outputs[slot]
- if output ~= nil then
- if output.rawName == "item.beeprincessge" then
- apiary.pushItem("down", slot)
- apiary.pullItem("down", 1)
- print("Placed Princess in slot 1")
- elseif output.rawName == "item.beedronege" then
- if apiary.getStackInSlot(slot).qty > 1 then
- apiary.pushItemIntoSlot("up", slot, apiary.getStackInSlot(slot).qty - 1)
- end
- apiary.pushItem("down", slot)
- apiary.pullItem("down", 1)
- print("Placed Drone in slot 2")
- else
- apiary.pushItem("up", slot, 64, 0)
- print("Placed Comb in chest")
- end
- end
- end
- end
- while true do
- if apiary.getStackInSlot(1) == nil then
- resetApiary()
- chest.condenseItems()
- end
- sleep(1)
- end
Advertisement
Add Comment
Please, Sign In to add comment