pitrey

turtle bois

Jan 30th, 2016
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ID = nil
  2. turtle.select(1)
  3.  
  4. function fuel()
  5.  fuellvl =  turtle.getFuelLevel()
  6. if (fuellvl == 0) then
  7.  turtle.select(16)
  8.  turtle.refuel()
  9.  turtle.select(1)
  10.  end
  11.  end
  12.  while true do
  13.  if turtle.compare() == true then
  14.  sleep(10)
  15.  else
  16.  turtle.select(2)
  17.  while (turtle.compare() == true) do
  18.  turtle.dig()
  19.  turtle.digUp()
  20.  fuel()
  21.  turtle.up()
  22.  end
  23.  while (turtle.detectDown() == false) do
  24.  turtle.down()
  25.  end
  26.  turtle.turnLeft()
  27.  ID = turtle.getItemCount() - 1
  28.  turtle.drop(ID)
  29.  turtle.select(3)
  30.  turtle.drop()
  31.  turtle.turnRight()
  32.  turtle.select(1)
  33.  if turtle.getItemCount() == 0 then
  34.  turtle.turnRight()
  35.  turtle.suck(1)
  36.  turtle.turnLeft()
  37.  end
  38.   turtle.suck()
  39.  turtle.place()
  40.  end
  41.  end
Add Comment
Please, Sign In to add comment