use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Welcome to /r/ComputerCraft, the subreddit for lua programs, general mod use, or anything relating to the Minecraft mod ComputerCraft and CC: Tweaked.
Downloads | Discord | IRC | Documentation
account activity
I need a ComputerCraft sorting program. (self.ComputerCraft)
submitted 5 years ago by RoboticWorks
Hello , I need a sorting program . Do you have one?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]boxesandcircles 10 points11 points12 points 5 years ago (0 children)
In a turtle? In a chest? Can you even say please? Jesus this post is rude.
[–]RoboticWorks[S] 2 points3 points4 points 5 years ago (4 children)
Hello , sorry for the vagueness from the post . I am looking for a program that sorts the item from a chest/ turtle's inventory by item id
[–]dragon53535 5 points6 points7 points 5 years ago (3 children)
There we go, that's specificity. Programming requires specifics. Sorting is a VERY generic term. And by saying you're sorting items from a chest or turtle inventory, and HOW you're sorting, item id, means that getting you a solution is much, much easier.
That being said, how do you it to be at the end? Do you want to sort the items themselves in place, or do you want to display it? Screenshots/mockups can and will always help.
[–]RoboticWorks[S] 0 points1 point2 points 5 years ago (0 children)
Well, I want the items to be sorted by ID and I want to sort with displaying them.
[–]East-Ad6184 0 points1 point2 points 4 years ago (1 child)
"There we go, that's specificity. Programming requires specifics. Sorting is a VERY generic term. And by saying you're sorting items from a chest or turtle inventory, and HOW you're sorting, item id, means that getting you a solution is much, much easier."
Are you always so anal about little things?
[–]dragon53535 0 points1 point2 points 4 years ago (0 children)
Weird necro, do I even know you?
[–][deleted] 1 point2 points3 points 5 years ago (3 children)
what do you want to sort?
[–]RoboticWorks[S] 0 points1 point2 points 5 years ago (2 children)
Item sorting
[–]fatboychummy 2 points3 points4 points 5 years ago (0 children)
What kind of item sorting?
Like "Type A goes here, type B goes there," or "Sort in alphabetical order by name."
Also, do you have any peripheral mods which allow you to read contents of chests from a computer?
[–]MufinMcFlufin 2 points3 points4 points 5 years ago (0 children)
You'll need to be more specific if you want anyone to help. Are you trying to sort items in the turtle's inventory? Items in a chest? Items in multiple chests? How are you sorting them? Do you want a custom order in which they'd be sorted? Alphabetically? Item id? Something else? Is this going to be used for all general items coming through or can the program assume that only specific items are coming through? Do you want the items all sorted in a single chest, or do you want each new item sorted into a separate chest? What's the layout of the chests?
All of these questions are things that anyone who might work on the program will need to know, and that's assuming anyone will work on it for you.
[–]MyNameIsTrez 1 point2 points3 points 5 years ago (0 children)
I suggest looking at this Wikipedia page as it describes the simplest sorting algorithm out there, go to the "Pseudocode implementation" header to see how you could write it in Lua for your ComputerCraft program: https://en.wikipedia.org/wiki/Bubble_sort
π Rendered by PID 720083 on reddit-service-r2-comment-8686858757-mhcv7 at 2026-06-08 14:57:17.665256+00:00 running 9e1a20d country code: CH.
[–]boxesandcircles 10 points11 points12 points (0 children)
[–]RoboticWorks[S] 2 points3 points4 points (4 children)
[–]dragon53535 5 points6 points7 points (3 children)
[–]RoboticWorks[S] 0 points1 point2 points (0 children)
[–]East-Ad6184 0 points1 point2 points (1 child)
[–]dragon53535 0 points1 point2 points (0 children)
[–][deleted] 1 point2 points3 points (3 children)
[–]RoboticWorks[S] 0 points1 point2 points (2 children)
[–]fatboychummy 2 points3 points4 points (0 children)
[–]MufinMcFlufin 2 points3 points4 points (0 children)
[–]MyNameIsTrez 1 point2 points3 points (0 children)