Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function checkFuel()
- count = 0
- fuelLevel = turtle.getFuelLevel()
- while fuelLevel <= 10 and repcount <= 5000 do
- for i = 1,16 do
- turtle.select(i)
- itemInfo = turtle.getItemDetail()
- if itemInfo ~= nil then
- if itemInfo.name == "minecraft:coal" then
- turtle.refuel()
- print("Refueled ", itemInfo["count"], " coal from slot", i)
- end
- end
- end
- count = count + 1
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement