mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 16:32:54 +08:00
Make circles light up 1 beat length before start time
This commit is contained in:
parent
b7f43405fc
commit
639e8b62b9
@ -59,6 +59,8 @@ namespace osu.Game.Rulesets.Osu.Mods
|
|||||||
private const byte border_distance_x = 192;
|
private const byte border_distance_x = 192;
|
||||||
private const byte border_distance_y = 144;
|
private const byte border_distance_y = 144;
|
||||||
|
|
||||||
|
private ControlPointInfo controlPointInfo;
|
||||||
|
|
||||||
public bool PerformFail()
|
public bool PerformFail()
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
@ -77,13 +79,14 @@ namespace osu.Game.Rulesets.Osu.Mods
|
|||||||
Seed.Value ??= RNG.Next();
|
Seed.Value ??= RNG.Next();
|
||||||
|
|
||||||
var osuBeatmap = (OsuBeatmap)beatmap;
|
var osuBeatmap = (OsuBeatmap)beatmap;
|
||||||
|
controlPointInfo = osuBeatmap.ControlPointInfo;
|
||||||
var origHitObjects = osuBeatmap.HitObjects.OrderBy(x => x.StartTime).ToList();
|
var origHitObjects = osuBeatmap.HitObjects.OrderBy(x => x.StartTime).ToList();
|
||||||
|
|
||||||
var hitObjects = generateBeats(osuBeatmap, origHitObjects)
|
var hitObjects = generateBeats(osuBeatmap, origHitObjects)
|
||||||
.Select(x =>
|
.Select(x =>
|
||||||
{
|
{
|
||||||
var newCircle = new HitCircle();
|
var newCircle = new HitCircle();
|
||||||
newCircle.ApplyDefaults(osuBeatmap.ControlPointInfo, osuBeatmap.BeatmapInfo.BaseDifficulty);
|
newCircle.ApplyDefaults(controlPointInfo, osuBeatmap.BeatmapInfo.BaseDifficulty);
|
||||||
newCircle.StartTime = x;
|
newCircle.StartTime = x;
|
||||||
return (OsuHitObject)newCircle;
|
return (OsuHitObject)newCircle;
|
||||||
}).ToList();
|
}).ToList();
|
||||||
@ -136,7 +139,7 @@ namespace osu.Game.Rulesets.Osu.Mods
|
|||||||
|
|
||||||
var avgColour = colour.AverageColour.Linear;
|
var avgColour = colour.AverageColour.Linear;
|
||||||
drawable.FadeColour(new Color4(avgColour.R * 0.45f, avgColour.G * 0.45f, avgColour.B * 0.45f, avgColour.A))
|
drawable.FadeColour(new Color4(avgColour.R * 0.45f, avgColour.G * 0.45f, avgColour.B * 0.45f, avgColour.A))
|
||||||
.Then().Delay(h.TimeFadeIn).FadeColour(colour);
|
.Then().Delay(h.TimePreempt - controlPointInfo.TimingPointAt(h.StartTime).BeatLength).FadeColour(colour);
|
||||||
|
|
||||||
// remove approach circles
|
// remove approach circles
|
||||||
circle.ApproachCircle.Hide();
|
circle.ApproachCircle.Hide();
|
||||||
|
Loading…
Reference in New Issue
Block a user