Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local station = peripheral.find("powah:energizing_orb")
- local recipe = {}
- local stationlist = {}
- local slot1 = ""
- local slot2 = ""
- local slot3 = ""
- local slot4 = ""
- local stationslot1 = ""
- local stationslot2 = ""
- local stationslot3 = ""
- local stationslot4 = ""
- local firstLoop = true
- while true do
- if not (turtle.getSelectedSlot() == 5) then
- turtle.select(5)
- end
- if turtle.getItemDetail(5) then
- slot1 = turtle.getItemDetail(5).name
- else
- slot1 = ""
- end
- if turtle.getItemDetail(6) then
- slot2 = turtle.getItemDetail(6).name
- else
- slot2 = ""
- end
- if turtle.getItemDetail(7) then
- slot3 = turtle.getItemDetail(7).name
- else
- slot3 = ""
- end
- if turtle.getItemDetail(8) then
- slot4 = turtle.getItemDetail(8).name
- else
- slot4 = ""
- end
- recipe = {slot1, slot2, slot3, slot4}
- for i=5,8 do
- turtle.select(i)
- if turtle.getItemDetail(turtle.getSelectedSlot()) then
- turtle.drop(1)
- end
- end
- if station.getItemDetail(2) then
- stationslot1 = station.getItemDetail(2).name
- else
- stationslot1 = ""
- end
- if station.getItemDetail(3) then
- stationslot2 = station.getItemDetail(3).name
- else
- stationslot2 = ""
- end
- if station.getItemDetail(4) then
- stationslot3 = station.getItemDetail(4).name
- else
- stationslot3 = ""
- end
- if station.getItemDetail(5) then
- stationslot4 = station.getItemDetail(5).name
- else
- stationslot4 = ""
- end
- stationlist = {stationslot1, stationslot2, stationslot3, stationslot4}
- while stationlist[1] == recipe[1] do
- if station.getItemDetail(2) then
- stationslot1 = station.getItemDetail(2).name
- else
- stationslot1 = ""
- end
- if station.getItemDetail(3) then
- stationslot2 = station.getItemDetail(3).name
- else
- stationslot2 = ""
- end
- if station.getItemDetail(4) then
- stationslot3 = station.getItemDetail(4).name
- else
- stationslot3 = ""
- end
- if station.getItemDetail(5) then
- stationslot4 = station.getItemDetail(5).name
- else
- stationslot4 = ""
- end
- stationlist = {stationslot1, stationslot2, stationslot3, stationslot4}
- sleep(0.5)
- print("Not Ready")
- end
- print("Ready")
- turtle.select(1)
- turtle.suck(1)
- recipe = {}
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement