vreezer

Crafty Turtle 1:2:1 *4*4*4

Mar 29th, 2014
231
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. anz = 0
  2. schlaf = 0.05
  3. count = 64
  4. side = "back"
  5. function cut()
  6.         sleep(schlaf)
  7.         shell.run("clear")
  8.         sleep(schlaf)
  9. end
  10. ----------------------------------------
  11. function suck()
  12.        
  13.         turtle.select(num)  
  14.         sleep(0.08)
  15.         turtle.dropDown()
  16.         sleep(0.08)          
  17.         turtle.suckDown()
  18.         sleep(0.08)
  19.         m = turtle.getItemCount(num)
  20.         sleep(0.08)
  21.  
  22.         if m == 0 then
  23.         shell.run("reboot")
  24.         else
  25.         m1 = m - 1
  26.         turtle.dropDown(m1)
  27.        
  28.         sleep(5)
  29.         anz = anz+1
  30.  
  31.         end
  32. end
  33. ----------------------------------------
  34. function doIt()
  35.        
  36.         turtle.select(16)
  37.         sleep(0.2)
  38.            turtle.craft()
  39.            sleep(0.8)
  40.            turtle.dropUp()
  41.            sleep(0.8)
  42.         print(" Gecraftete Items : " .. anz)
  43.         cut()
  44. end
  45.  
  46.  
  47. while true do
  48.         while rs.getInput(side) == true do
  49.         num = 2
  50.         suck()
  51.         num = 3
  52.         suck()
  53.         num = 5
  54.         suck()
  55.         num = 6
  56.         suck()
  57.         doIt()
  58.        
  59.  
  60.  
  61.         end
  62.         print("Kein Signal")
  63.         cut()
  64. end
Advertisement
Add Comment
Please, Sign In to add comment