r/ComputerCraft • u/RoboticWorks • Sep 19 '20
I need a ComputerCraft sorting program.
Hello , I need a sorting program . Do you have one?
2
Sep 19 '20
what do you want to sort?
1
u/RoboticWorks Sep 19 '20
Item sorting
3
u/fatboychummy Sep 19 '20
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?
3
u/MufinMcFlufin Sep 19 '20
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.
10
u/boxesandcircles Sep 19 '20
In a turtle? In a chest? Can you even say please? Jesus this post is rude.
2
u/MyNameIsTrez Sep 19 '20
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
4
u/RoboticWorks Sep 19 '20
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