Advertisement
NiallDoherty

Fuel Up

Apr 13th, 2019
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. tank = peripheral.wrap("left")
  2.  
  3. while true do
  4. if tank.suck() then
  5. tank.fill(1)
  6. turtle.refuel()
  7. end
  8. if(turtle.getFuelLevel() == turtle.getFuelLimit()) then
  9. print("Fuel limit reached!")
  10. return
  11. end
  12. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement