Guest User

turtleShortenCommands

a guest
Jun 15th, 2014
293
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.66 KB | None | 0 0
  1. --[[  T U R T L E  S H O R T E N
  2.            C O M M A N D S
  3.       ComputerCraft Turtles API
  4.                 created by sysPL  ]]--
  5.                
  6. --On the start of your program code,
  7. --type os.loadApi("turtleShortenCommands")
  8.  
  9. --API Functions
  10.  
  11. --Craft (for crafty turtles)
  12. function craft(quantity)
  13.  turtle.craft(quantity)
  14. end
  15.  
  16. --Fwd (for all turtles)
  17. function fwd()
  18.  turtle.forward()
  19. end
  20.  
  21. --Up (for all turtles)
  22. function up()
  23.  turtle.up()
  24. end
  25.  
  26. --Dwn (for all turtles)
  27. function dwn()
  28.  turtle.down()
  29. end
  30.  
  31. --L (for all turtles)
  32. function l()
  33.  turtle.turnLeft()
  34. end
  35.  
  36. --R (for all turtles)
  37. function r()
  38.  turtle.turnRight()
  39. end
  40.  
  41. --Sel (for all turtles)
  42. function select(slot)
  43.  turtle.select(slot)
  44. end
  45.  
  46. --El (for all turtles)
  47. function el()
  48.  turtle.equipLeft()
  49. end
  50.  
  51. --Er (for all turtles)
  52. function er()
  53.  turtle.equipRight()
  54. end
  55.  
  56. --Atk (any tool)
  57. function atk()
  58.  turtle.attack()
  59. end
  60.  
  61. --Dig (Mining, felling, digging, farming OR with equipped item)
  62. function dig()
  63.  turtle.dig()
  64. end
  65.  
  66. --Dup (like dig)
  67. function dup()
  68.  turtle.digUp()
  69. end
  70.  
  71. --Ddwn (like dig)
  72. function ddwn()
  73.  turtle.digDown()
  74. end
  75.  
  76. --Place (all turtles)
  77. function place()
  78.  turtle.place()
  79. end
  80.  
  81. --Pup (all turtles)
  82. function pup()
  83.  turtle.placeUp()
  84. end
  85.  
  86. --Pdwn (all turtles)
  87. function pdwn()
  88.  turtle.placeDown()
  89. end
  90.  
  91. --Drop (all turtles)
  92. function drop(dquantity)
  93.  turtle.drop(dquantity)
  94. end
  95.  
  96. --Refuel (all turtles)
  97. function refuel(rquantity)
  98.  turtle.refuel(rquantity)
  99. end
  100.  
  101. --All commands wrote by sysPL.
  102. --Use it for free in your applications.
  103. --Commands shorten from CC - Turtle API.
  104. --They are not by me.
  105. --                 Cheers - sysPL/syseQ
Advertisement
Add Comment
Please, Sign In to add comment