1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 12:17:26 +08:00

style: use normalised CornerRadius values

This commit is contained in:
tsrk 2023-03-06 20:11:52 +00:00
parent 952814604e
commit fc0e27fb15
No known key found for this signature in database
GPG Key ID: EBD46BB3049B56D6

View File

@ -16,10 +16,10 @@ namespace osu.Game.Screens.Play.HUD
public partial class PlayerAvatar : CompositeDrawable, ISerialisableDrawable
{
[SettingSource(typeof(SkinnableComponentStrings), nameof(SkinnableComponentStrings.CornerRadius), nameof(SkinnableComponentStrings.CornerRadiusDescription))]
public new BindableFloat CornerRadius { get; set; } = new BindableFloat
public new BindableFloat CornerRadius { get; set; } = new BindableFloat(0.25f)
{
MinValue = 0,
MaxValue = 64,
MaxValue = 0.5f,
Precision = 0.01f
};
@ -43,7 +43,7 @@ namespace osu.Game.Screens.Play.HUD
base.LoadComplete();
avatar.User = gameplayState.Score.ScoreInfo.User;
CornerRadius.BindValueChanged(e => avatar.CornerRadius = e.NewValue, true);
CornerRadius.BindValueChanged(e => avatar.CornerRadius = e.NewValue * 128f, true);
}
public bool UsesFixedAnchor { get; set; }