overshoot

Turtle Monitor Test

Feb 18th, 2017
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. -- Harvest Rows of Cane
  2. -- 170218 Upgraded to three sets
  3.  
  4. RowLength=10
  5. NumSetsCrop=3
  6. NumMinHarvest=10
  7.  
  8.  
  9. -- Function to Connect to Monitor
  10. local mon
  11. local function findMonitor()
  12. mon = peripheral.wrap("right")
  13.  
  14. if mon then
  15. return true
  16. else
  17. return false
  18. end
  19. end -- Function find monitor
  20.  
  21.  
  22. -------------------------
  23. -- Main Routine
  24. -------------------------
  25. MonExists=findMonitor()
  26. print("Name: ", os.getComputerLabel() )
  27. if MonExists then
  28. mon.setTextScale(3)
  29. mon.write("Monitor")
  30. else
  31. print("No Monitor")
  32. end -- if
  33.  
  34. if turtle.getFuelLevel()<100 then
  35. print("Out of Fuel: ", turtle.getFuelLevel())
  36. end
Advertisement
Add Comment
Please, Sign In to add comment