Use IScoreInfo in ExtendedScore instead of SoloScoreInfo#299
Open
TextAdventurer12 wants to merge 2 commits intoppy:masterfrom
Open
Use IScoreInfo in ExtendedScore instead of SoloScoreInfo#299TextAdventurer12 wants to merge 2 commits intoppy:masterfrom
TextAdventurer12 wants to merge 2 commits intoppy:masterfrom
Conversation
stanriders
requested changes
Feb 14, 2026
| public class ExtendedScore | ||
| { | ||
| public SoloScoreInfo SoloScore { get; } | ||
| public IScoreInfo Score { get; } |
Member
There was a problem hiding this comment.
Why not just ScoreInfo? The only reason this is using SoloScoreInfo now is because the data is always sourced from the API so it was convenient, but we convert it to ScoreInfo anyway to run pp calculation
| private const float performance_background_shear = 0.45f; | ||
|
|
||
| public readonly ExtendedScore Score; | ||
| public readonly ExtendedScore ExtScore; |
Member
There was a problem hiding this comment.
Suggested change
| public readonly ExtendedScore ExtScore; | |
| public readonly ExtendedScore ExtendedScore; |
| private partial class ScorePerformanceContainer : OsuHoverContainer | ||
| { | ||
| private readonly ExtendedScore score; | ||
| private readonly ExtendedScore extScore; |
Member
There was a problem hiding this comment.
Suggested change
| private readonly ExtendedScore extScore; | |
| private readonly ExtendedScore extendedScore; |
| public partial class ScoreContainer : Container | ||
| { | ||
| public ExtendedScore Score { get; } | ||
| public ExtendedScore ExtScore { get; } |
Member
There was a problem hiding this comment.
Suggested change
| public ExtendedScore ExtScore { get; } | |
| public ExtendedScore ExtendedScore { get; } |
|
|
||
| // IScoreInfo is missing statistics right now, but both SoloScoreInfo and ScoreInfo have it (and I believe it's planned for future) | ||
| // I think handling conversion at this level is the most elegant, although it means supporting any additional types that inherit from IScoreInfo will need to be manually added here | ||
| public Dictionary<HitResult, int>? Statistics |
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 means that
ExtendedScoreworks for bothSoloScoreInfofrom the API andScoreInfofrom other sources (like realm).Renamed most places that used
ExtendedScore ScoretoExtendedScore ExtScorebecauseSoloScoredoesn't work well as a name anymore and I thinkScore.Scoresounds stupid.StatisticsandModsneed manual conversions because osu-side infrastructure is a bit of a mess around them.