Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- term.clear()
- term.setCursorPos(1,1)
- print("Place chests in slot 1.")
- print("Place light sources in slot 2.")
- print("")
- print("How big would you like the pyramid to be?")
- write("-> ")
- count=tonumber(read())
- count=count-1
- term.clear()
- term.setCursorPos(1,1)
- print("Now running. Make sure to keep chests in slot 1 and light sources in slot 2!")
- if turtle.getItemCount(2)==0 then
- placeTorches=false
- else
- placeTorches=true
- hasTorches=true
- end
- left=0
- right=1
- turn=right
- turtle.select(2)
- while count > 0 do
- countHold=count+1
- moves=count+1
- while countHold > 0 do
- countHold=countHold-1
- countAmount=count
- if moves > 0 then
- moves=moves-1
- while countAmount > 0 do
- turtle.dig()
- while turtle.detect()==true do
- turtle.dig()
- end
- turtle.forward()
- countAmount=countAmount-1
- end
- end
- if moves > 0 then
- if turn==right then
- turtle.turnRight()
- turtle.dig()
- while turtle.detect()==true do
- turtle.dig()
- end
- turtle.forward()
- turtle.turnRight()
- turn=left
- else
- turtle.turnLeft()
- turtle.dig()
- while turtle.detect()==true do
- turtle.dig()
- end
- turtle.forward()
- turtle.turnLeft()
- turn=right
- end
- end
- if turtle.getItemCount(16) > 0 then
- turtle.select(1)
- turtle.digDown()
- turtle.turnLeft()
- turtle.turnLeft()
- turtle.placeDown()
- times=3
- while times <= 16 do
- turtle.select(times)
- turtle.dropDown()
- times=times+1
- end
- turtle.turnRight()
- turtle.turnRight()
- turtle.select(2)
- end
- end
- if turn==left then
- turtle.turnRight()
- turtle.dig()
- turtle.forward()
- if placeTorches==true then
- if hasTorches==true then
- if turtle.getItemCount(2)==1 then
- hasTorches=false
- end
- turtle.turnLeft()
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.turnRight()
- turtle.turnRight()
- end
- end
- turtle.turnRight()
- turtle.dig()
- turtle.forward()
- turtle.turnLeft()
- turtle.digDown()
- turtle.down()
- turn=right
- else
- turtle.turnLeft()
- turtle.dig()
- turtle.forward()
- if placeTorches==true then
- if hasTorches==true then
- if turtle.getItemCount(2)==1 then
- hasTorches=false
- end
- turtle.turnLeft()
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.turnRight()
- turtle.turnRight()
- end
- end
- turtle.turnLeft()
- turtle.dig()
- while turtle.detect()==true do
- turtle.dig()
- end
- turtle.forward()
- turtle.turnRight()
- turtle.digDown()
- turtle.down()
- turn=left
- end
- count=count-2
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement