Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- length = {...}
- slot = 1
- place = 1
- turtle.select(1)
- function line()
- while turtle.getItemCount(tonumber(length[1])) > 0 do
- for i = 1, 64 do
- turtle.select(slot)
- turtle.forward()
- turtle.placeDown()
- end
- slot = slot +1
- end
- end
- function up()
- while turtle.getItemCount(tonumber(length[1])) > 0 do
- for i = 1, 64 do
- turtle.select(slot)
- turtle.up()
- turtle.forward()
- turtle.placeDown()
- end
- slot = slot +1
- end
- end
- function down()
- while turtle.getItemCount(tonumber(length[1])) > 0 do
- for i = 1, 64 do
- turtle.select(slot)
- turtle.forward()
- turtle.down()
- turtle.placeDown()
- end
- slot = slot +1
- end
- end
- function row()
- turtle.select(slot)
- for i = 1, tonumber(length[1]) do
- getMats = turtle.getItemCount(slot)
- if getMats == 0 then
- slot = slot +1
- turtle.select(slot)
- end
- turtle.placeDown()
- place = place +1
- turtle.forward()
- end
- end
- function rowBack()
- turtle.turnRight()
- turtle.turnRight()
- for i = 1, tonumber(length[1]) do
- turtle.forward()
- end
- end
- function start()
- turtle.forward()
- turtle.turnLeft()
- for i = 1, (tonumber(length[1])-1) / 2 do
- turtle.forward()
- end
- turtle.turnRight()
- end
- function platform()
- slot = 1
- start()
- for i = 1, tonumber(length[1]) do
- row()
- rowBack()
- turtle.turnLeft()
- turtle.forward()
- turtle.turnLeft()
- end
- end
- slot = 1
- if length[2] == "up" then up()
- elseif length[2] == "down" then down()
- elseif length[2] == "platform" then platform()
- else line()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement