mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
Merge branch 'master' into cancel-select-random
This commit is contained in:
@ -54,7 +54,7 @@ namespace osu.Game.Screens.Menu
|
||||
{
|
||||
Masking = true,
|
||||
MaskingSmoothness = 2,
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Shadow,
|
||||
Colour = Color4.Black.Opacity(0.2f),
|
||||
|
@ -47,7 +47,7 @@ namespace osu.Game.Screens.Multiplayer
|
||||
Height = height;
|
||||
CornerRadius = 5;
|
||||
Masking = true;
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Shadow,
|
||||
Colour = Color4.Black.Opacity(40),
|
||||
|
@ -57,7 +57,7 @@ namespace osu.Game.Screens.Play.HUD
|
||||
return;
|
||||
glowColour = value;
|
||||
|
||||
fill.EdgeEffect = new EdgeEffect
|
||||
fill.EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = glowColour.Opacity(base_glow_opacity),
|
||||
Radius = 8,
|
||||
|
@ -164,7 +164,7 @@ namespace osu.Game.Screens.Play
|
||||
AutoSizeAxes = Axes.Y,
|
||||
Direction = FillDirection.Vertical,
|
||||
Masking = true,
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Shadow,
|
||||
Colour = Color4.Black.Opacity(0.6f),
|
||||
|
@ -36,19 +36,6 @@ namespace osu.Game.Screens.Ranking
|
||||
}
|
||||
}
|
||||
|
||||
public override bool Active
|
||||
{
|
||||
get
|
||||
{
|
||||
return base.Active;
|
||||
}
|
||||
set
|
||||
{
|
||||
base.Active = value;
|
||||
colouredPart.FadeColour(Active ? activeColour : inactiveColour, 200, EasingTypes.OutQuint);
|
||||
}
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuColour colours)
|
||||
{
|
||||
@ -60,7 +47,7 @@ namespace osu.Game.Screens.Ranking
|
||||
activeColour = colours.PinkDarker;
|
||||
inactiveColour = OsuColour.Gray(0.8f);
|
||||
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = Color4.Black.Opacity(0.4f),
|
||||
Type = EdgeEffectType.Shadow,
|
||||
@ -104,5 +91,9 @@ namespace osu.Game.Screens.Ranking
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
protected override void OnActivated() => colouredPart.FadeColour(activeColour, 200, EasingTypes.OutQuint);
|
||||
|
||||
protected override void OnDeactivated() => colouredPart.FadeColour(inactiveColour, 200, EasingTypes.OutQuint);
|
||||
}
|
||||
}
|
||||
|
@ -134,7 +134,7 @@ namespace osu.Game.Screens.Ranking
|
||||
circleOuter = new CircularContainer
|
||||
{
|
||||
Size = new Vector2(circle_outer_scale),
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = Color4.Black.Opacity(0.4f),
|
||||
Type = EdgeEffectType.Shadow,
|
||||
@ -225,7 +225,7 @@ namespace osu.Game.Screens.Ranking
|
||||
circleInner = new CircularContainer
|
||||
{
|
||||
Size = new Vector2(0.6f),
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = Color4.Black.Opacity(0.4f),
|
||||
Type = EdgeEffectType.Shadow,
|
||||
|
@ -50,7 +50,7 @@ namespace osu.Game.Screens.Ranking
|
||||
},
|
||||
new CircularContainer
|
||||
{
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = colours.GrayF.Opacity(0.8f),
|
||||
Type = EdgeEffectType.Shadow,
|
||||
@ -74,7 +74,7 @@ namespace osu.Game.Screens.Ranking
|
||||
},
|
||||
content = new CircularContainer
|
||||
{
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Colour = Color4.Black.Opacity(0.2f),
|
||||
Type = EdgeEffectType.Shadow,
|
||||
|
@ -80,8 +80,8 @@ namespace osu.Game.Screens.Select
|
||||
lookup.Success += res =>
|
||||
{
|
||||
if (beatmap != requestedBeatmap)
|
||||
//the beatmap has been changed since we started the lookup.
|
||||
return;
|
||||
//the beatmap has been changed since we started the lookup.
|
||||
return;
|
||||
|
||||
requestedBeatmap.Metrics = res;
|
||||
Schedule(() => updateMetrics(res));
|
||||
@ -89,6 +89,7 @@ namespace osu.Game.Screens.Select
|
||||
lookup.Failure += e => updateMetrics(null);
|
||||
|
||||
api.Queue(lookup);
|
||||
loading.Show();
|
||||
}
|
||||
|
||||
updateMetrics(requestedBeatmap.Metrics, false);
|
||||
@ -104,6 +105,9 @@ namespace osu.Game.Screens.Select
|
||||
var hasRatings = metrics?.Ratings.Any() ?? false;
|
||||
var hasRetriesFails = (metrics?.Retries.Any() ?? false) && metrics.Fails.Any();
|
||||
|
||||
if (failOnMissing)
|
||||
loading.Hide();
|
||||
|
||||
if (hasRatings)
|
||||
{
|
||||
var ratings = metrics.Ratings.ToList();
|
||||
@ -320,11 +324,13 @@ namespace osu.Game.Screens.Select
|
||||
}
|
||||
},
|
||||
},
|
||||
}
|
||||
},
|
||||
loading = new LoadingAnimation()
|
||||
};
|
||||
}
|
||||
|
||||
private APIAccess api;
|
||||
private readonly LoadingAnimation loading;
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuColour colour, APIAccess api)
|
||||
|
@ -36,7 +36,7 @@ namespace osu.Game.Screens.Select
|
||||
Masking = true;
|
||||
BorderColour = new Color4(221, 255, 255, 255);
|
||||
BorderThickness = 2.5f;
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Glow,
|
||||
Colour = new Color4(130, 204, 255, 150),
|
||||
|
@ -12,6 +12,7 @@ using System;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Threading;
|
||||
using osu.Game.Database;
|
||||
using osu.Game.Graphics.UserInterface;
|
||||
using osu.Game.Rulesets.Scoring;
|
||||
using osu.Game.Online.API;
|
||||
using osu.Game.Online.API.Requests;
|
||||
@ -25,6 +26,8 @@ namespace osu.Game.Screens.Select.Leaderboards
|
||||
|
||||
public Action<Score> ScoreSelected;
|
||||
|
||||
private readonly LoadingAnimation loading;
|
||||
|
||||
private IEnumerable<Score> scores;
|
||||
public IEnumerable<Score> Scores
|
||||
{
|
||||
@ -86,6 +89,7 @@ namespace osu.Game.Screens.Select.Leaderboards
|
||||
},
|
||||
},
|
||||
},
|
||||
loading = new LoadingAnimation()
|
||||
};
|
||||
}
|
||||
|
||||
@ -117,6 +121,7 @@ namespace osu.Game.Screens.Select.Leaderboards
|
||||
}
|
||||
|
||||
private GetScoresRequest getScoresRequest;
|
||||
|
||||
private void updateScores()
|
||||
{
|
||||
if (!IsLoaded) return;
|
||||
@ -126,8 +131,14 @@ namespace osu.Game.Screens.Select.Leaderboards
|
||||
|
||||
if (api == null || Beatmap == null) return;
|
||||
|
||||
loading.Show();
|
||||
|
||||
getScoresRequest = new GetScoresRequest(Beatmap);
|
||||
getScoresRequest.Success += r => Scores = r.Scores;
|
||||
getScoresRequest.Success += r =>
|
||||
{
|
||||
Scores = r.Scores;
|
||||
loading.Hide();
|
||||
};
|
||||
api.Queue(getScoresRequest);
|
||||
}
|
||||
|
||||
|
@ -147,7 +147,7 @@ namespace osu.Game.Screens.Select.Leaderboards
|
||||
CornerRadius = corner_radius,
|
||||
Masking = true,
|
||||
OnLoadComplete = d => d.FadeInFromZero(200),
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Shadow,
|
||||
Radius = 1,
|
||||
|
@ -99,7 +99,7 @@ namespace osu.Game.Screens.Select.Options
|
||||
RelativeSizeAxes = Axes.Both,
|
||||
Shear = new Vector2(0.2f, 0f),
|
||||
Masking = true,
|
||||
EdgeEffect = new EdgeEffect
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
{
|
||||
Type = EdgeEffectType.Shadow,
|
||||
Colour = Color4.Black.Opacity(0.2f),
|
||||
|
Reference in New Issue
Block a user