So, I revisited the algorithm as a whole and came up with a much smarter method which will still work through all possible permutations to find the best scheduling match possible but does so in order rather than all up front, thus no memory issue.
This method of scheduling I call the "bubble" method. The concept is to first "pure" pair all participants by their current battle points. Then sort that list.
Then starting at position 0, begin working the way down the list, finding the first possible match (as in not played before and not in the same group). When found, mark for both. Move to next position and start searching down the list again with the next position + 1. Continue doing this. If a conflict occurs where it is not possible to find a match, bubble up to the previous match and re-match the previous but starting at the last match + 1 in the list. Continue this process till a solid schedule is found or until you have completely bubbled back out of the list. If a complete bubble occurs, perform the same algorithm, this time only rejecting "played before". If still bubbles out, reject only "groups". If still bubbles out, scheduling is impossible so just return the Pure pairing.
I corrected a major issue where player passwords were not being correctly accepted to enter in scores.
I also added some more notifications to file creations to inform you of what kind of file you are creating rather than just showing you a save file dialog.
Download Beta Version 1.1 here:
No comments:
Post a Comment
Due to spam, all comments are moderated.
Pat
Note: Only a member of this blog may post a comment.