Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local dirtFull = false;
- local dirtCount = 0;
- local cobblestoneFull = false;
- local cobblestoneCount = 0;
- for i=1,16,1 do
- local t = turtle.getItemDetail(i);
- if (t and t.name == 'minecraft:dirt') then
- turtle.select(i);
- local r = turtle.drop();
- if r then
- dirtCount = dirtCount + t.count;
- else
- dirtFull = true;
- end
- end
- end
- print('Stored ',dirtCount,' of dirt');
- turtle.turnRight();
- for i=1,16,1 do
- local t = turtle.getItemDetail(i);
- if (t and t.name == 'minecraft:cobblestone') then
- turtle.select(i);
- local r = turtle.drop();
- if r then
- cobblestoneCount = cobblestoneCount + t.count;
- else
- cobblestoneFull = true;
- end
- end
- end
- print('Stored ',cobblestoneCount,' of cobblestone');
- turtle.turnLeft();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement