Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local x=0
- local y=0
- local z=0
- local z1=0
- local length=0
- local i=0
- local c=0
- local b=0
- local r=1
- local build
- local d=0
- function check()
- while turtle.getItemCount(r)<10 do
- r=r+1
- end
- turtle.select(r)
- end
- function Ground(length)
- y=0
- x=0
- while y<length do
- while x<length do
- check()
- turtle.dig()
- turtle.forward()
- turtle.digDown()
- turtle.placeDown()
- x=x+1
- end
- check()
- y=y+1
- if y%2==0 then
- turtle.dig()
- turtle.forward()
- turtle.turnRight()
- turtle.dig()
- turtle.forward()
- turtle.turnRight()
- else
- turtle.dig()
- turtle.forward()
- turtle.turnLeft()
- turtle.dig()
- turtle.forward()
- turtle.turnLeft()
- end
- x=0
- end
- while z<(length+1) do
- check()
- turtle.dig()
- turtle.forward()
- z=z+1
- end
- turtle.turnLeft()
- while z1<length do
- turtle.dig()
- turtle.forward()
- z1=z1+1
- end
- turtle.turnLeft()
- end
- function Reihe(length)
- for b=0, 3, 1 do
- for c=0, (length-2), 1 do
- check()
- turtle.placeDown()
- turtle.dig()
- turtle.forward()
- end
- turtle.turnLeft()
- end
- end
- function Wall(length)
- turtle.forward()
- for i=0, 4, 1 do
- turtle.digUp()
- turtle.up()
- Reihe(length)
- end
- end
- function Skylight()
- for d=0, 3, 1 do
- turtle.select(14)
- turtle.digDown()
- turtle.placeDown()
- turtle.forward()
- turtle.turnRight()
- end
- end
- function Dach()
- x=0
- y=0
- z=0
- Skylight()
- turtle.forward()
- turtle.forward()
- turtle.forward()
- Skylight()
- turtle.forward()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.forward()
- Skylight()
- turtle.forward()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.forward()
- Skylight()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.turnLeft()
- for x=0, 5, 1 do
- turtle.back()
- end
- for y=0, 4, 1 do
- turtle.down()
- end
- turtle.dig()
- turtle.down()
- turtle.dig()
- for z=0, 1, 1 do
- turtle.forward()
- end
- end
- function Innen()
- x=0
- turtle.turnLeft()
- for x=0, 2, 1 do
- turtle.forward()
- end
- turtle.turnRight()
- turtle.up()
- for y=0, 2, 1 do
- Fenster()
- turtle.turnRight()
- end
- turtle.forward()
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.up()
- turtle.dig()
- turtle.place()
- turtle.turnRight()
- x=0
- for x=0, 3, 1 do
- turtle.forward()
- end
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.down()
- turtle.dig()
- turtle.place()
- turtle.back()
- turtle.back()
- turtle.back()
- turtle.turnLeft()
- turtle.forward()
- turtle.forward()
- turtle.up()
- end
- function Fenster()
- x=0
- for x=0, 1, 1 do
- turtle.forward()
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.up()
- turtle.dig()
- turtle.place()
- turtle.turnRight()
- turtle.forward()
- turtle.turnLeft()
- turtle.dig()
- turtle.place()
- turtle.down()
- turtle.dig()
- turtle.place()
- turtle.turnRight()
- turtle.forward()
- end
- end
- function Finish()
- x=0
- turtle.select(13)
- for x=0, 3, 1 do
- turtle.forward()
- turtle.forward()
- turtle.place()
- turtle.back()
- turtle.back()
- turtle.turnLeft()
- end
- turtle.down()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.forward()
- turtle.select(15)
- turtle.placeDown()
- turtle.forward()
- turtle.forward()
- turtle.turnRight()
- turtle.turnRight()
- turtle.select(16)
- turtle.down()
- turtle.place()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.turnRight()
- end
- term.write(" Welche Laenge soll das Haus haben? ")
- length=read()
- length=tonumber(length)
- term.write(" Working... ")
- Ground(length)
- Wall(length)
- turtle.back()
- turtle.up()
- Ground(length)
- if length==9 then
- turtle.back()
- turtle.back()
- turtle.back()
- turtle.turnRight()
- turtle.forward()
- turtle.forward()
- turtle.forward()
- Dach()
- Innen()
- Finish()
- term.write(" Fertig ")
- end
Add Comment
Please, Sign In to add comment