Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local turnLeft=true;
- local failCount=0;
- local breakFloor=true;
- local sel=0;
- local slot=1
- print("floor/ceiling builder by Niseg")
- print("refuel the turtle put it in a a corner facing out")
- turtle.select(slot)
- repeat
- print("break the (1) ceiling ")
- print("break the (2) floor")
- sel=tonumber(read())
- until sel==1 or sel==2
- if(sel==1) then breakFloor=false end
- repeat
- print("empty side on (1) right ")
- print("empty side on (2) left")
- sel=tonumber(read())
- until sel==1 or sel==2
- if(sel==1) then turnLeft=false end
- while true do
- if breakFloor then
- turtle.placeDown()
- --if not breakFloor then
- else
- turtle.placeUp()
- end
- if turtle.getItemCount(slot)==0 then
- slot=slot+1
- turtle.select(slot)
- end
- if(not turtle.forward()) then
- if(turnLeft) then turtle.turnLeft() else turtle.turnRight() end
- if not turtle.forward() then break end
- if(turnLeft) then turtle.turnLeft() else turtle.turnRight() end
- turnLeft = not turnLeft;
- end
- end
- print("done")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement