Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Salt maker startup
- term.clear()
- term.setCursorPos(1,1)
- print("Salt Maker V1")
- local chest = peripheral.find("minecraft:chest")
- local turtleDir = "south" --Can also be turtle network name
- assert(chest,"Chest not found, check that the chest name is correct")
- if turtle.getItemCount(3)~=0 and chest.pullItems(turtleDir,3,64) == 0 then --Because the turtle more than likely has something at start.
- print("Chest Full, Shutting down!")
- return
- end
- turtle.select(1)
- --assert(chest)
- while true do
- turtle.select(1)
- turtle.place()
- turtle.select(3)
- turtle.craft(1)
- if turtle.getItemCount(3)~=0 and chest.pullItems(turtleDir,3,64) == 0 then --resets turtle facing before ending the program
- print("Chest Full, Shutting down!")
- return
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement