Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function main()
- build(getSpecs())
- end
- function getSpecs()
- print("Use only barrels if this is for storage")
- print("What length for storage building?")
- local l = read()
- print("What width?")
- local w = read()
- print("How high?")
- local h = read()
- return l,w,h
- end
- function build(l,w,h)
- --Orient the turtle
- turtle.digUp()
- turtle.up()
- --Check for reload
- reload = 1
- for i=1,h do
- if turtle.getItemCount() < 16 then
- turtle.select(reload + 1)
- reload = reload + 1
- end
- for i=1,l do
- turtle.dig()
- turtle.digDown()
- turtle.placeDown()
- turtle.forward()
- print(turtle.getItemCount())
- end
- turtle.back()
- turtle.turnRight()
- turtle.forward()
- for i=1,w-1 do
- turtle.dig()
- turtle.digDown()
- turtle.placeDown()
- turtle.forward()
- print(turtle.getItemCount())
- end
- turtle.back()
- turtle.turnRight()
- turtle.forward()
- for i=1,l-1 do
- turtle.dig()
- turtle.digDown()
- turtle.placeDown()
- turtle.forward()
- print(turtle.getItemCount())
- end
- turtle.back()
- turtle.turnRight()
- turtle.forward()
- for i=1,w-1 do
- turtle.dig()
- turtle.digDown()
- turtle.placeDown()
- turtle.forward()
- end
- turtle.back()
- turtle.turnRight()
- turtle.digUp()
- turtle.up()
- end
- turtle.down()
- turtle.back()
- for i=1,h do
- turtle.down()
- end
- end
- main()
Add Comment
Please, Sign In to add comment