Skip to content

Fix ranking#29

Open
Arnaud-D wants to merge 2 commits intoMorelGames:masterfrom
Arnaud-D:fix_ranks
Open

Fix ranking#29
Arnaud-D wants to merge 2 commits intoMorelGames:masterfrom
Arnaud-D:fix_ranks

Conversation

@Arnaud-D
Copy link
Contributor

Before this PR, players with the same score are ranked equally, and the following player would then have this rank plus one.

This PR implements ranking as seen usually in tournaments: players with the same score are ranked equally, and following players are then ranked using their position in the sorted list of scores.

Anyway, the code is a better description of what is happening. ^^

QA

  • create a game,
  • have three players (at least) playing,
  • make the first two have the same score and the third one a lower score,
  • observe that the ranking is : 1st, 1st, 3rd (instead of 1st, 1st, 2nd before this PR).

@AmauryCarrade AmauryCarrade added the enhancement New feature or request label Jan 23, 2022
Co-authored-by: Amaury Carrade <amaury@carrade.eu>
@AmauryCarrade AmauryCarrade self-assigned this Jul 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants