Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.loadAPI("sortapi");
- local sorter = { peripheral.wrap("left"), peripheral.wrap("back") };
- local chestdir = { sortapi.dir("west"), sortapi.dir("south") };
- local outdir = { sortapi.dir("east"), sortapi.dir("north") };
- local limit = 5;
- print("Double Box Manager v1.0");
- print("By TTFTCUTS");
- while(true) do
- if ( redstone.getInput("right") ) then
- break;
- end
- for i=1,2 do
- local box = sorter[i].list( chestdir[i] );
- sleep(0.1);
- if box then
- for k,v in pairs(box) do
- if (v>limit) then
- sorter[i].extract( chestdir[i], k, outdir[i], v-limit );
- end
- sleep(0.05);
- end
- sleep(0.1);
- end
- end
- sleep(5);
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement