Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local width, height, depth = 1,1,1
- if (arg[1]) then
- width = tonumber(arg[1])
- end
- if (arg[2]) then
- height = tonumber(arg[2])
- end
- if (arg[3]) then
- depth = tonumber(arg[3])
- end
- print("Width: " .. width .. ", Height: " .. height .. ", Depth: " .. depth)
- while turtle.getFuelLevel() < turtle.getFuelLimit() do
- local itemInfo = turtle.getItemDetail(1)
- print(textutils.serialize(itemInfo))
- if (itemInfo == nil) then
- print(turtle.getFuelLevel() .. "/" .. turtle.getFuelLimit())
- break
- elseif (itemInfo.name == "minecraft:coal" or itemInfo.name == "minecraft:charcoal") then
- turtle.select(1)
- turtle.refuel(1)
- end
- end
- local has_block, data = turtle.inspect()
- if has_block then
- print(textutils.serialize(data))
- print(turtle.dig())
- print(turtle.forward())
- print(turtle.turnRight())
- else
- print(turtle.forward())
- print(turtle.turnRight())
- end
- for i=1,depth,1 do
- for j=1,height,1 do
- for k=1,width-1,1 do
- print("Width: "..k..", Height: "..j..", Depth: "..i)
- turtle.dig()
- turtle.forward()
- end
- for x=width,1,-1 do
- turtle.back()
- end
- if j < height then
- turtle.digUp()
- turtle.up()
- end
- end
- for y=height,1,-1 do
- turtle.down()
- end
- if i < depth then
- turtle.turnLeft()
- turtle.dig()
- turtle.forward()
- turtle.turnRight()
- end
- end
Add Comment
Please, Sign In to add comment