local function blockbelow()
slot = 1
while turtle.getItemCount(slot) <= 1 do
slot = slot + 1
turtle.select(slot)
end
turtle.placeDown()
end
Now this is used within the script that places the blocks for the building.
local function build()
turtle.forward()
blockbelow()
turtle.forward()
blockbelow()
end
I just typed that, since it would be kind of big to copy the entire thing. The thing that happens now is that for every block, it checks how many left, and goes through the entire inventory causing somewhat of a delay and slowing the process down, nonetheless, it works, but I feel like it can be better.
I have two questions with this which are most likely very easy, but I'm just not seeing the solution :P/>
- How do I make it so it does not go through the entire inventory, but keeps the slot selected until it runs out
Thanks ahead :)/>