Zekrommaster110

[COMPUTERCRAFT] Mining Programm V1.0

Jul 26th, 2015
369
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.13 KB | None | 0 0
  1. function clear()
  2.     shell.run("clear")
  3. end
  4.  
  5. function s1()
  6.     turtle.dig()
  7.     turtle.forward()
  8.     test()
  9.     turtle.digUp()
  10. end
  11.  
  12. function test()
  13.     if turtle.detectDown()==false then
  14.         turtle.select(2)
  15.         turtle.placeDown()
  16.         print("false")
  17.     end
  18. end
  19.  
  20. ---------------------------------------------------
  21. -- START
  22. clear()
  23. print("\n  <-[MINING PROGRAM V1.0]->")
  24. print("  (C) Zekrommaster110 2015\n")
  25. sleep(1,8)
  26.  
  27. clear()
  28. write("\n Bitte anzahl der Gaenge eingeben: ")
  29. local gaenge = read()
  30.  
  31. clear()
  32. write("\nIn Slot 1 bitte ")
  33. write(gaenge)
  34. write(" Fackeln legen.\n\n")
  35. local nullinput = read()
  36.  
  37.  
  38. -- MINING PROGRAMM
  39. for strip = 1, gaenge, 1 do
  40.     s1()
  41.     s1()
  42.     s1()
  43.     turtle.back()
  44.     turtle.select(1)
  45.     turtle.placeUp()
  46.     turtle.forward()
  47.     test()
  48.     turtle.turnRight()
  49.     for s2 = 1, 4, 1 do
  50.         s1()
  51.     end
  52.     turtle.turnRight()
  53.     turtle.turnRight()
  54.     for s2 = 1, 8, 1 do
  55.         s1()
  56.     end
  57.     turtle.turnRight()
  58.     turtle.turnRight()
  59.     for s2 = 1, 4, 1 do
  60.         s1()
  61.     end
  62.     turtle.turnLeft()
  63. end
  64.  
  65. back = gaenge*3
  66. turtle.turnRight()
  67. turtle.turnRight()
  68. for goback = 1, back, 1 do
  69.     turtle.forward()
  70.     test()
  71. end
  72.  
  73. -- (C) Zekrommaster110 2015
Advertisement
Add Comment
Please, Sign In to add comment