mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 05:32:54 +08:00
Fix post-merge issues
This commit is contained in:
parent
29422345f7
commit
050af88be9
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Osu.Objects;
|
using osu.Game.Rulesets.Osu.Objects;
|
||||||
using OpenTK;
|
|
||||||
|
|
||||||
namespace osu.Game.Rulesets.Osu.Edit.Blueprints
|
namespace osu.Game.Rulesets.Osu.Edit.Blueprints
|
||||||
{
|
{
|
||||||
@ -13,7 +13,7 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public abstract class SliderPiece : HitObjectPiece
|
public abstract class SliderPiece : HitObjectPiece
|
||||||
{
|
{
|
||||||
protected readonly IBindable<Vector2[]> ControlPointsBindable = new Bindable<Vector2[]>();
|
protected readonly IBindable<SliderPath> PathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
private readonly Slider slider;
|
private readonly Slider slider;
|
||||||
|
|
||||||
@ -26,7 +26,7 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints
|
|||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load()
|
private void load()
|
||||||
{
|
{
|
||||||
ControlPointsBindable.BindTo(slider.ControlPointsBindable);
|
PathBindable.BindTo(slider.PathBindable);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints.Sliders.Components
|
|||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load()
|
private void load()
|
||||||
{
|
{
|
||||||
ControlPointsBindable.BindValueChanged(_ => updatePathControlPoints(), true);
|
PathBindable.BindValueChanged(_ => updatePathControlPoints(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updatePathControlPoints()
|
private void updatePathControlPoints()
|
||||||
|
@ -3,15 +3,15 @@
|
|||||||
|
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Osu.Edit.Blueprints.HitCircles.Components;
|
using osu.Game.Rulesets.Osu.Edit.Blueprints.HitCircles.Components;
|
||||||
using osu.Game.Rulesets.Osu.Objects;
|
using osu.Game.Rulesets.Osu.Objects;
|
||||||
using OpenTK;
|
|
||||||
|
|
||||||
namespace osu.Game.Rulesets.Osu.Edit.Blueprints.Sliders.Components
|
namespace osu.Game.Rulesets.Osu.Edit.Blueprints.Sliders.Components
|
||||||
{
|
{
|
||||||
public class SliderCirclePiece : HitCirclePiece
|
public class SliderCirclePiece : HitCirclePiece
|
||||||
{
|
{
|
||||||
private readonly IBindable<Vector2[]> controlPointsBindable = new Bindable<Vector2[]>();
|
private readonly IBindable<SliderPath> pathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
private readonly Slider slider;
|
private readonly Slider slider;
|
||||||
private readonly SliderPosition position;
|
private readonly SliderPosition position;
|
||||||
@ -26,8 +26,8 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints.Sliders.Components
|
|||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load()
|
private void load()
|
||||||
{
|
{
|
||||||
controlPointsBindable.BindValueChanged(_ => UpdatePosition());
|
pathBindable.BindTo(slider.PathBindable);
|
||||||
controlPointsBindable.BindTo(slider.ControlPointsBindable);
|
pathBindable.BindValueChanged(_ => UpdatePosition(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void UpdatePosition()
|
protected override void UpdatePosition()
|
||||||
|
@ -11,6 +11,7 @@ using osu.Framework.Allocation;
|
|||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
using osu.Framework.Graphics.Containers;
|
using osu.Framework.Graphics.Containers;
|
||||||
using osu.Game.Configuration;
|
using osu.Game.Configuration;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Scoring;
|
using osu.Game.Rulesets.Scoring;
|
||||||
using OpenTK.Graphics;
|
using OpenTK.Graphics;
|
||||||
|
|
||||||
@ -29,7 +30,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
|
|
||||||
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
||||||
private readonly IBindable<float> scaleBindable = new Bindable<float>();
|
private readonly IBindable<float> scaleBindable = new Bindable<float>();
|
||||||
private readonly IBindable<Vector2[]> controlPointsBindable = new Bindable<Vector2[]>();
|
private readonly IBindable<SliderPath> pathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
public DrawableSlider(Slider s)
|
public DrawableSlider(Slider s)
|
||||||
: base(s)
|
: base(s)
|
||||||
@ -103,11 +104,11 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
Ball.Scale = new Vector2(HitObject.Scale);
|
Ball.Scale = new Vector2(HitObject.Scale);
|
||||||
});
|
});
|
||||||
|
|
||||||
controlPointsBindable.BindValueChanged(_ => Body.Refresh());
|
|
||||||
|
|
||||||
positionBindable.BindTo(HitObject.PositionBindable);
|
positionBindable.BindTo(HitObject.PositionBindable);
|
||||||
scaleBindable.BindTo(HitObject.ScaleBindable);
|
scaleBindable.BindTo(HitObject.ScaleBindable);
|
||||||
controlPointsBindable.BindTo(slider.ControlPointsBindable);
|
pathBindable.BindTo(slider.PathBindable);
|
||||||
|
|
||||||
|
pathBindable.BindValueChanged(_ => Body.Refresh());
|
||||||
}
|
}
|
||||||
|
|
||||||
public override Color4 AccentColour
|
public override Color4 AccentColour
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Objects.Types;
|
using osu.Game.Rulesets.Objects.Types;
|
||||||
using OpenTK;
|
using OpenTK;
|
||||||
|
|
||||||
@ -12,7 +13,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
public class DrawableSliderHead : DrawableHitCircle
|
public class DrawableSliderHead : DrawableHitCircle
|
||||||
{
|
{
|
||||||
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
||||||
private readonly IBindable<Vector2[]> controlPointsBindable = new Bindable<Vector2[]>();
|
private readonly IBindable<SliderPath> pathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
private readonly Slider slider;
|
private readonly Slider slider;
|
||||||
|
|
||||||
@ -25,11 +26,11 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
[BackgroundDependencyLoader]
|
[BackgroundDependencyLoader]
|
||||||
private void load()
|
private void load()
|
||||||
{
|
{
|
||||||
positionBindable.BindValueChanged(_ => updatePosition());
|
|
||||||
controlPointsBindable.BindValueChanged(_ => updatePosition());
|
|
||||||
|
|
||||||
positionBindable.BindTo(HitObject.PositionBindable);
|
positionBindable.BindTo(HitObject.PositionBindable);
|
||||||
controlPointsBindable.BindTo(slider.ControlPointsBindable);
|
pathBindable.BindTo(slider.PathBindable);
|
||||||
|
|
||||||
|
positionBindable.BindValueChanged(_ => updatePosition());
|
||||||
|
pathBindable.BindValueChanged(_ => updatePosition(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void Update()
|
protected override void Update()
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
using osu.Framework.Configuration;
|
using osu.Framework.Configuration;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Scoring;
|
using osu.Game.Rulesets.Scoring;
|
||||||
using OpenTK;
|
using OpenTK;
|
||||||
|
|
||||||
@ -20,7 +21,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
public bool Tracking { get; set; }
|
public bool Tracking { get; set; }
|
||||||
|
|
||||||
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
private readonly IBindable<Vector2> positionBindable = new Bindable<Vector2>();
|
||||||
private readonly IBindable<Vector2[]> controlPointsBindable = new Bindable<Vector2[]>();
|
private readonly IBindable<SliderPath> pathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
public DrawableSliderTail(Slider slider, SliderTailCircle hitCircle)
|
public DrawableSliderTail(Slider slider, SliderTailCircle hitCircle)
|
||||||
: base(hitCircle)
|
: base(hitCircle)
|
||||||
@ -34,11 +35,11 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
|
|
||||||
AlwaysPresent = true;
|
AlwaysPresent = true;
|
||||||
|
|
||||||
positionBindable.BindValueChanged(_ => updatePosition());
|
|
||||||
controlPointsBindable.BindValueChanged(_ => updatePosition());
|
|
||||||
|
|
||||||
positionBindable.BindTo(hitCircle.PositionBindable);
|
positionBindable.BindTo(hitCircle.PositionBindable);
|
||||||
controlPointsBindable.BindTo(slider.ControlPointsBindable);
|
pathBindable.BindTo(slider.PathBindable);
|
||||||
|
|
||||||
|
positionBindable.BindValueChanged(_ => updatePosition());
|
||||||
|
pathBindable.BindValueChanged(_ => updatePosition(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void CheckForResult(bool userTriggered, double timeOffset)
|
protected override void CheckForResult(bool userTriggered, double timeOffset)
|
||||||
|
@ -51,19 +51,12 @@ namespace osu.Game.Rulesets.Osu.Objects
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private SliderPath path;
|
public readonly Bindable<SliderPath> PathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
public SliderPath Path
|
public SliderPath Path
|
||||||
{
|
{
|
||||||
get => path;
|
get => PathBindable.Value;
|
||||||
set
|
set => PathBindable.Value = value;
|
||||||
{
|
|
||||||
path = value;
|
|
||||||
|
|
||||||
PathChanged?.Invoke(value);
|
|
||||||
if (TailCircle != null)
|
|
||||||
TailCircle.Position = EndPosition;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public double Distance => Path.Distance;
|
public double Distance => Path.Distance;
|
||||||
@ -162,7 +155,7 @@ namespace osu.Game.Rulesets.Osu.Objects
|
|||||||
ComboIndex = ComboIndex,
|
ComboIndex = ComboIndex,
|
||||||
};
|
};
|
||||||
|
|
||||||
TailCircle = new SliderTailCircle
|
TailCircle = new SliderTailCircle(this)
|
||||||
{
|
{
|
||||||
StartTime = EndTime,
|
StartTime = EndTime,
|
||||||
Position = EndPosition,
|
Position = EndPosition,
|
||||||
|
@ -1,13 +1,23 @@
|
|||||||
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
||||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||||
|
|
||||||
|
using osu.Framework.Configuration;
|
||||||
using osu.Game.Rulesets.Judgements;
|
using osu.Game.Rulesets.Judgements;
|
||||||
|
using osu.Game.Rulesets.Objects;
|
||||||
using osu.Game.Rulesets.Osu.Judgements;
|
using osu.Game.Rulesets.Osu.Judgements;
|
||||||
|
|
||||||
namespace osu.Game.Rulesets.Osu.Objects
|
namespace osu.Game.Rulesets.Osu.Objects
|
||||||
{
|
{
|
||||||
public class SliderTailCircle : SliderCircle
|
public class SliderTailCircle : SliderCircle
|
||||||
{
|
{
|
||||||
|
private readonly IBindable<SliderPath> pathBindable = new Bindable<SliderPath>();
|
||||||
|
|
||||||
|
public SliderTailCircle(Slider slider)
|
||||||
|
{
|
||||||
|
pathBindable.BindTo(slider.PathBindable);
|
||||||
|
pathBindable.BindValueChanged(_ => Position = slider.EndPosition);
|
||||||
|
}
|
||||||
|
|
||||||
public override Judgement CreateJudgement() => new OsuSliderTailJudgement();
|
public override Judgement CreateJudgement() => new OsuSliderTailJudgement();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user