CloneWith / osu

Another osu! client fork, tailored for tournament hosting
https://osu.ppy.sh
MIT License
1 stars 0 forks source link

New design for boxes in Board & EX scene #20

Closed NaughtyChas closed 3 months ago

NaughtyChas commented 3 months ago

Seems that the text inside the boxes are making the board screen seems too complex, several changes can be taken into account:

Probably have to extend these design into EX screen?


Adding DifficultyIcon to EX screen would be a lot better:

without DifficultyIcon with DifficultyIcon
image image
NaughtyChas commented 3 months ago
  • [x] Remove artist from title
  • [x] Add text truncate effect (...) to the title
  • [x] Remove "mapper", Beatmap?.Metadata.Author.Username and "difficulty" text.

commit 9460514 solve these three tasks at once:

image

We have to apply the same display scheme to EX screen.

NaughtyChas commented 3 months ago
  • [x] Add DifficultyIcon to EX screen

Commit cc9f688 added these StarRatingDisplay to EX screen:

image

Definition of StarRatingDisplay is:

public StarRatingDisplay(StarDifficulty starDifficulty, StarRatingDisplaySize size = StarRatingDisplaySize.Regular, bool animated = false)
{
    // content
}

Considering adding animation by setting bool animated = true.

CloneWith commented 3 months ago

Considering adding animation by setting bool animated = true.

Have just tried this, but there doesn't seem to be any visible animation.

Does the animation play upon load? I think this is highly possible.

NaughtyChas commented 3 months ago

Considering adding animation by setting bool animated = true.

Have just tried this, but there doesn't seem to be any visible animation.

Does the animation play upon load? I think this is highly possible.

I believe that the animation has to set with correct parameters. See file StarRatingDisplay.cs:

        protected override void LoadComplete()
        {
            base.LoadComplete();

            Current.BindValueChanged(c =>
            {
                if (animated)
                    this.TransformBindableTo(displayedStars, c.NewValue.Stars, 750, Easing.OutQuint);
                else
                    displayedStars.Value = c.NewValue.Stars;
            });

            // other content
        }

...if animated is true, it animates the transition of displayedStars to the new value over 750 milliseconds using the Easing.OutQuint easing function. Might be crucial to define suitable values for these parameters.


Might be possible to set the animation using this approach?

// Initialize with 0.00 star rating
starRatingDisplay = new StarRatingDisplay(new StarDifficulty(0, 0), StarRatingDisplaySize.Regular, true)

// Update the star rating to the actual value, triggering the animation.
starRatingDisplay.Current.Value = new StarDifficulty(Beatmap?.StarRating ?? 0, 0);

If we have set the correct parameters, it should play animation play upon load I suppose. There is a high chance where the animation has already loaded before we switch into EX Screen.

Maybe we can considering the use of TournamentSceneManager.cs, when EXBoardScreen is active, trigger that animation.

NaughtyChas commented 3 months ago

Animation will not being considered, now we can close this issue.