Advertisement
rungholt

tfillxy

Aug 6th, 2023 (edited)
1,014
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.87 KB | None | 0 0
  1. local args = { ... }
  2. local x = tonumber(args[1])
  3. local y = tonumber(args[2])
  4. --local z = tonumber(args[3])
  5.  
  6. local function placeX()
  7.     for i = 1, x - 1 do
  8.         turtle.back()
  9.         turtle.select(i)
  10.         turtle.place()
  11.     end
  12. end
  13.  
  14. local function change()
  15.     turtle.up()
  16.     turtle.select(1)
  17.     turtle.placeDown()
  18.     turtle.turnLeft()
  19.     turtle.turnLeft()
  20. end
  21.  
  22. local function goDown()
  23.     turtle.turnLeft()
  24.     turtle.back()
  25.     turtle.select(1)
  26.     turtle.place()
  27.     for j = 1, y - 1 do
  28.         turtle.down()
  29.     end
  30. end
  31.  
  32. local function placeXY()
  33.     for k = 1, y - 1 do
  34.         placeX()
  35.         change()
  36.     end
  37.     placeX()
  38.     goDown()
  39. end
  40.  
  41. local function start()
  42.     placeXY()
  43. end
  44.  
  45. start()
  46.  
  47. --[[local function digXYZ()
  48.     for l = 1, z do
  49.         startMine()
  50.         digXY()
  51.         goBack()
  52.     end
  53. end
  54.  
  55. digXYZ()]]--
  56.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement