mirror of
https://github.com/osukey/osukey.git
synced 2025-08-07 00:23:59 +09:00
Fix medal overlay display
This commit is contained in:
@ -41,11 +41,17 @@ namespace osu.Game.Overlays
|
||||
|
||||
private SampleChannel getSample;
|
||||
|
||||
private readonly Container content;
|
||||
|
||||
public MedalOverlay(Medal medal)
|
||||
{
|
||||
this.medal = medal;
|
||||
RelativeSizeAxes = Axes.Both;
|
||||
|
||||
Child = content = new Container
|
||||
{
|
||||
Alpha = 0,
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
Children = new Drawable[]
|
||||
{
|
||||
background = new Box
|
||||
@ -139,7 +145,10 @@ namespace osu.Game.Overlays
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
};
|
||||
|
||||
Show();
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
@ -168,7 +177,7 @@ namespace osu.Game.Overlays
|
||||
}, loaded =>
|
||||
{
|
||||
disc.Add(loaded);
|
||||
Show();
|
||||
startAnimation();
|
||||
});
|
||||
}
|
||||
|
||||
@ -193,11 +202,10 @@ namespace osu.Game.Overlays
|
||||
private const double initial_duration = 400;
|
||||
private const double step_duration = 900;
|
||||
|
||||
protected override void PopIn()
|
||||
private void startAnimation()
|
||||
{
|
||||
base.PopIn();
|
||||
content.Show();
|
||||
|
||||
this.FadeIn(200);
|
||||
background.FlashColour(Color4.White.Opacity(0.25f), 400);
|
||||
|
||||
getSample.Play();
|
||||
|
Reference in New Issue
Block a user