Kiliandeca

DecaMiner2: Create - init

Jan 19th, 2017
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.63 KB | None | 0 0
  1. if not turtle then
  2.     for i, side in pairs(rs.getSides()) do
  3.         if disk.isPresent(side) then
  4.             disk.setLabel(side, "DecaMiner2")
  5.             shell.run("delete disk/startup")        
  6.             shell.run("pastebin get Jks5fsgV disk/startup")
  7.             print("Floppy ready, remove the computer")
  8.         end
  9.     end
  10.  
  11. else
  12.  
  13.     _, errorstr = turtle.dig()
  14.  
  15.     if errorstr == "No tool to dig with" then
  16.         -- place
  17.         shell.run("pastebin get PHrmrWwk startup")
  18.         os.reboot()
  19.     else
  20.         -- recup
  21.         shell.run("pastebin get JSyuXnAS startup")
  22.         os.reboot()
  23.     end
  24. end
Add Comment
Please, Sign In to add comment