Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function checkDirection(direction)
- if direction == true then
- turtle.turnRight()
- else
- turtle.turnLeft()
- end
- end
- quarryDimensions = 16
- local SLOT_COUNT = 16
- DROPPED_ITEMS = {
- "minecraft:stone",
- "minecraft:dirt",
- "minecraft:cobblestone",
- "minecraft:sand",
- "minecraft:gravel",
- "minecraft:redstone",
- "minecraft:flint",
- "railcraft:ore_metal",
- "extrautils2:ingredients",
- "minecraft:dye",
- "thaumcraft:nugget",
- "thaumcraft:crystal_essence",
- "thermalfoundation:material",
- "projectred-core:resource_item",
- "thaumcraft:ore_cinnabar",
- "deepresonance:resonating_ore",
- "forestry:apatite",
- "quark:limestone"
- }
- function dropItems()
- print("Purging Inventory...")
- for slot = 1, SLOT_COUNT, 1 do
- local item = turtle.getItemDetail(slot)
- if(item ~= nil) then
- for filterIndex = 1, #DROPPED_ITEMS, 1 do
- if(item["name"] == DROPPED_ITEMS[filterIndex]) then
- print("Dropping - " .. item["name"])
- turtle.select(slot)
- turtle.dropDown()
- end
- end
- end
- end
- end
- direction = true
- while (5 > 1) do
- a = 0
- repeat
- i = 0
- repeat
- turtle.dig()
- turtle.forward()
- i = i + 1
- until (i > quarryDimensions-1)
- if a < quarryDimensions then
- checkDirection(direction)
- turtle.dig()
- turtle.forward()
- checkDirection(direction)
- if direction == true then
- direction = false
- else
- direction = true
- end
- else
- print("Stopped")
- end
- a = a + 1
- until (a > quarryDimensions)
- turtle.turnRight()
- j = 0
- repeat
- turtle.forward()
- j = j + 1
- print(j)
- until (j > quarryDimensions-1)
- turtle.turnRight()
- turtle.digDown()
- turtle.down()
- direction = true
- dropItems()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement