Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- shell.run("label set raritySorter")
- local reader = peripheral.find("blockReader")
- local keepers = {epic=true, mythic=true}
- function sort()
- turtle.select(1)
- turtle.suck()
- if turtle.getItemCount() > 0 then
- local status, rarity = pcall(getRarity)
- if status and keepers[rarity] then
- turtle.dropUp()
- else
- turtle.dropDown()
- end
- end
- end
- function getRarity()
- return reader.getBlockData()["Items"][0]["tag"]["affix_data"]["rarity"]
- end
- while true do
- sort()
- sort()
- sort()
- sort()
- os.sleep(1)
- end
Advertisement
Add Comment
Please, Sign In to add comment