Skip to content

Sort currencies by name and exchange rate for better change generation#5

Open
posadist-revolution wants to merge 1 commit intoboxfriend:masterfrom
posadist-revolution:master
Open

Sort currencies by name and exchange rate for better change generation#5
posadist-revolution wants to merge 1 commit intoboxfriend:masterfrom
posadist-revolution:master

Conversation

@posadist-revolution
Copy link

I noticed that using the unsorted list of currencies made it so that the change returned from buying items from merchants was very strangely formatted and unpleasant (often giving a ton of emerald and heliodor chips instead of larger denominations, if I remember correctly.) This change sorts currencies alphabetically (mainly to make sure that diamond marks are always returned for single-mark values) and then sorts them by value, highest to lowest (to return the smallest possible number of spheres by going for high-value spheres first.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant