Add sorting options and settings persistence to Request Pipe - #84
Open
ModularityEnjoyer wants to merge 2 commits into
Open
Add sorting options and settings persistence to Request Pipe#84ModularityEnjoyer wants to merge 2 commits into
ModularityEnjoyer wants to merge 2 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds sorting options (Count Descending, Count Ascending, ID Descending, ID Ascending), settings persistence within game sessions (sorting, pull, craft, partial), and a few minor GUI tweaks to the Request Pipe.
Prior to this, the default (and only) sorting order was by item ID, which felt rather pointless. I've considered that this limitation could be intentional, to prevent the Request Pipe from being some form of early-game AE2 alternative, but given the search functionality, it's safe to assume that the lack of proper sorting isn't a balancing decision.
The settings clearing themselves between every use of the Request Pipe was a personal friction point for me when using PR:T as my main storage system, and with the addition of sorting, I can only imagine it would become more frustrating.
I've also made an effort to get the UI elements lined up nicely, as they were a little funky before.
Firstly, the old GUI:
The new GUI, sorted by Count Descending (the new default):
Count Ascending:
ID Descending:
ID Ascending:
Given an equal count, the item with the lower ID will be listed first.
Sorry in advance for the weird integer case matching used for persistence. I did attempt to simplify this part by just storing the current sortMode, but Scala has taken everything from me and I simply have nothing left to give. If I've made any major blunders, or if anyone is unfortunate enough to have Scala experience and can help with a cleaner solution, please do.