Update 'Turtle/Turtle.lua'

This commit is contained in:
manuel 2023-01-08 18:24:27 +00:00
parent 57e08dcf07
commit 4ec5586b63

View File

@ -152,4 +152,28 @@ function Turtle:checkItemTag(tag, slot)
else else
return false return false
end end
end
function Wood:dropItemsDown(item, update)
assert(type(item) == "string", "item must be a string")
self:assertInvUpdate(update)
local tag = self:resolveTag(item)
if(tag == "") then
for i = 1, 16 do
if self:checkItemName(item, i) == true then
turtle.select(i)
turtle.dropDown()
end
end
else
for i = 1, 16 do
if self:checkItemTag(tag, i) == true then
turtle.select(i)
turtle.dropDown()
end
end
end
end end