Posted 20 January 2013 - 07:49 AM
I want to make a turtle suck saplings and bonemeal out of a chest and place it in his second and third slot? Is this possible? and if so how do i do it?
turtle.suck()
turtle.transferTo(slot, quantity)
Alright cool, can i make him suck out a specific item like lets say in the chest there is 4 items, in the first slot cobble stone, in the second saplings, in the third bonemeal, and in the forth wood, can i make the turtle suck out the second and third slots only?Turtle functions
Function turtle.suck() is the one you're looking for. If you want to place these items in nth slot, make sure it's selected first (turtle.select(…)) and that it's empty (turtle.getItemCount(…) == 0), otherwise it'll land in the next free slot.
Alright cool, can i make him suck out a specific item like lets say in the chest there is 4 items, in the first slot cobble stone, in the second saplings, in the third bonemeal, and in the forth wood, can i make the turtle suck out the second and third slots only?Turtle functions
Function turtle.suck() is the one you're looking for. If you want to place these items in nth slot, make sure it's selected first (turtle.select(…)) and that it's empty (turtle.getItemCount(…) == 0), otherwise it'll land in the next free slot.
for i = 1, 3 do
turtle.suck()
end
turtle.select(1)
turtle.drop()
Alright cool, thank you very much this has been helpful.Alright cool, can i make him suck out a specific item like lets say in the chest there is 4 items, in the first slot cobble stone, in the second saplings, in the third bonemeal, and in the forth wood, can i make the turtle suck out the second and third slots only?Turtle functions
Function turtle.suck() is the one you're looking for. If you want to place these items in nth slot, make sure it's selected first (turtle.select(…)) and that it's empty (turtle.getItemCount(…) == 0), otherwise it'll land in the next free slot.
You can only make it suck out a certain number of items, not from a certain slot
However, you can do something like,for i = 1, 3 do turtle.suck() end turtle.select(1) turtle.drop()
this sucks out 3 times, so the first, second and third slot
then it selects the first slot (the first item it sucked out of the chest) and dumps it back