Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- tArgs = {...}
- numBlocks = tArgs[1]
- local function length()
- local digLength = tonumber(numBlocks)
- if digLength < 5 or = 5 then
- printError("Shaft length must be greater than 5")
- return false
- elseif digLength > 5 then
- return digLength
- end
- end
- local function beginDig( dLength )
- if dLength ~= false then
- print("Digging a "..dLength.." block shaft...")
- end
- end
- local function dig( dLength2 )
- while x < dLength2 or = dLength2 do
- x = x + 1
- turtle.dig()
- turtle.forward()
- turtle.digUp()
- end
- end
- length()
- beginDig( digLength() )
- dig( digLength() )
Advertisement
Add Comment
Please, Sign In to add comment