Closed BlackYps closed 3 months ago
Attention: Patch coverage is 67.16418%
with 44 lines
in your changes are missing coverage. Please review.
Project coverage is 58.84%. Comparing base (
618ba92
) to head (fb2576a
).
The core functionality is there, but it is still a bit rough around the edges.
There is a slight delay because we have to fetch the division info from the api, so at the moment it behaves a bit ugly visually.
I appreciate input how this could be solved better.
Similarly the team title still displays (0) because I didn't manage to properly set the teamrating to null to trigger the removal of the rating display alltogether.
Edit: Fixed, but I don't know if the way I did it is good style
@BlackYps were you ever going to get back to this?
There have also been a few changes to the underlying objects as an FYI.
I don't plan to abandon this, on the other hand I am really not motivated to do the refactoring that is required here. So I guess the honest answer is, I really don't know...
Then I might just close this in a week and it can be reopened when you revisit it.
I'm picking this up again
The population of the values of the controllers and the displaying of these values are now nicely decoupled. There is one issue though. In a matchmaker game the people that don't have a division still display the rating and the team rating is displayed as well. The problem is that the player cards without a division don't know about the presence of divisions in different player cards. We need some way to check if we found any league stats for the replay (the api call) and then disable rating display for the whole thing somehow
For displaying the whole thing you can just have a display type enum that has a property in the player card. Then you can set that property appropriately to display either rating or league. Could even just bind it to some property in the parent.
I guess a boolean would even be enough, something like gameHasLeagueScore
. I don't have to differentiate multiple states, just this binary decision
Yeah I was just thinking of an enum to make it clearer what it signifies. Since hasLeagueScore doesn't imply as much that ratings won't be shown.
Where as something like display type would make that clearer.
yeah, I can see that.
Was testing this out and one thing that stuck out as a little bit odd to me. Why do we require pressing the show game result to show the game outcome on the team card. Maybe we should just display it always on load?
I think this kind as introduced to make it possible to watch a game without being spoiled on which side wins
Sure but now you can also play directly from the search result page
Hmm, that's true. Maybe we should discuss this with more users to better understand how they use this button at the moment. It's definitely an interesting suggestion, but imo it is unrelated to this PR
What is the status of this?
From my pov it is ready
Can I do something about that race condition?
You could make sure that you don't try to load the league data until after the team containers are populated
I think I first need to understand the race condition a little better. As I see it we run the risk that the league info is applied to the old teamcardcontrollers, so they get cleared right after and new controllers for the new replay get added in populateTeamsContainer if this happens after the application of the league info. Is this the correct one, or did you have a different race condition in mind? And why is createTeamCardControllers called asyncronously? I do not immediately see any operation in that method that would make this necessary.
They are created asynchronously so they don't block the application thread and cause the ui to freeze. And to cure the race condition you would just load the league info after create team controllers is called or make it apart of create team controllers
Showing division is nice, but was it necessary to remove the rating change? It means you need to check your profile after every match and keep a spreadsheet if you want to track changes rather than it being plainly displayed in the replays.
Yes, the divisions are supposed to replace the rating. The rating system is considered to be part of the backend, it's not necessary to show it to the user when the division system exists
Are we going to get transparency in how divisions are calculated? Currently divisions are more or less meaningless, every other system (ingame player lists, lobby entry requirements, matchmaking, game quality rating) works on rating.
Divisions are really large and imprecise, you could win 15 games in a row and see no change. Even systems that obfuscate Elo / MMR (eg LoL) show points to measure how far up or down you are inside a division.
What exactly is the problem you are having? I'm trying to und erstand it so I can hopefully address it in my answer. And did you have a look at the leaderboard tab? Your comment gives me the impression that you didn't, because you can see points there and it's not possible to win 15 games in a row without changing divisions, because each division is only 10 points big.
I wasn't aware about the Leaderboards or Score system at all. I was under the impression that division was based on rating (e.g. Gold V being 800 - 900).
This does answer my questions.
I still don't understand why you would hide information from the player, even if you consider rating to be back-end, but that's your prerogative.
WIP