Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --!wall
- --This is an accompaniment of !floor that wraps a room in walls
- print("How far forward boss?")
- local x=tonumber(read())-1
- print("How far across boss?")
- local y=tonumber(read())-1
- print("How far up boss?")
- local z=tonumber(read())
- print("Left or Right boss? (L/R)")
- local dir=read()
- if dir=="L" or dir=="l" then
- dir="L"
- elseif dir=="R" or dir=="r" then
- dir="R"
- end
- a=1
- if (2*x+2*y)*z+z<=turtle.getFuelLevel() then
- for k=1, z do
- t.up()
- for c=1, 2 do
- for i=1, x do
- if turtle.getItemCount(a)==0 then
- a=a+1
- elseif a==16 and turtle.getItemCount(a)==0 then
- break
- end
- turtle.select(a)
- turtle.placeDown(a)
- t.forward()
- if i==x then
- if dir=="R" then
- t.right()
- elseif dir=="L" then
- t.left()
- end
- end
- end
- for j=1, y do
- if turtle.getItemCount(a)==0 then
- a=a+1
- elseif a==16 and turtle.getItemCount(a)==0 then
- break
- end
- turtle.select(a)
- turtle.placeDown(a)
- t.forward()
- if j==y then
- if dir=="R" then
- t.right()
- elseif dir=="L" then
- t.left()
- end
- end
- end
- end
- if k==z then
- if dir=="L" then
- t.left()
- t.forward()
- t.right()
- t.forward()
- elseif dir=="R" then
- t.right()
- t.forward()
- t.left()
- t.forward()
- end
- t.down(z)
- end
- end
- else
- print("Not enough fuel! Shutting Down Now!")
- end
Advertisement
Add Comment
Please, Sign In to add comment