diff --git a/osu.Game.Rulesets.Mania/Edit/Blueprints/ManiaPlacementBlueprint.cs b/osu.Game.Rulesets.Mania/Edit/Blueprints/ManiaPlacementBlueprint.cs
index 184356b89c..3fb03d642f 100644
--- a/osu.Game.Rulesets.Mania/Edit/Blueprints/ManiaPlacementBlueprint.cs
+++ b/osu.Game.Rulesets.Mania/Edit/Blueprints/ManiaPlacementBlueprint.cs
@@ -24,15 +24,10 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
protected Column Column;
///
- /// The current beat-snapped mouse position, snapped to the closest column.
+ /// The current mouse position, snapped to the closest column.
///
protected Vector2 SnappedMousePosition { get; private set; }
- ///
- /// The gameplay time at the current beat-snapped mouse position ().
- ///
- protected double SnappedTime { get; private set; }
-
///
/// The width of the closest column to the current mouse position.
///
@@ -44,9 +39,6 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
[Resolved]
private IScrollingInfo scrollingInfo { get; set; }
- [Resolved(CanBeNull = true)]
- private IDistanceSnapProvider snapProvider { get; set; }
-
protected ManiaPlacementBlueprint(T hitObject)
: base(hitObject)
{
@@ -62,7 +54,7 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
return base.OnMouseDown(e);
HitObject.Column = Column.Index;
- BeginPlacement(SnappedTime, true);
+ BeginPlacement(TimeAt(e.ScreenSpaceMousePosition), true);
return true;
}
@@ -78,10 +70,6 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
// Snap to the column
var parentPos = Parent.ToLocalSpace(Column.ToScreenSpace(new Vector2(Column.DrawWidth / 2, 0)));
SnappedMousePosition = new Vector2(parentPos.X, Parent.ToLocalSpace(screenSpacePosition).Y);
-
- SnappedTime = TimeAt(screenSpacePosition);
- if (snapProvider != null)
- (SnappedMousePosition, SnappedTime) = snapProvider.GetSnappedPosition(SnappedMousePosition, SnappedTime);
}
protected double TimeAt(Vector2 screenSpacePosition)
diff --git a/osu.Game.Rulesets.Mania/Edit/ManiaHitObjectComposer.cs b/osu.Game.Rulesets.Mania/Edit/ManiaHitObjectComposer.cs
index 475320ece3..7677ac6f07 100644
--- a/osu.Game.Rulesets.Mania/Edit/ManiaHitObjectComposer.cs
+++ b/osu.Game.Rulesets.Mania/Edit/ManiaHitObjectComposer.cs
@@ -82,18 +82,9 @@ namespace osu.Game.Rulesets.Mania.Edit
public override (Vector2 position, double time) GetSnappedPosition(Vector2 position, double time)
{
- var beatSnapped = beatSnapGrid.GetSnappedPosition(position);
+ var hoc = Playfield.GetColumn(0).HitObjectContainer;
- if (beatSnapped != null)
- return beatSnapped.Value;
-
- return base.GetSnappedPosition(position, getTimeFromPosition(ToScreenSpace(position)));
- }
-
- private double getTimeFromPosition(Vector2 screenSpacePosition)
- {
- var hoc = Playfield.Stages[0].HitObjectContainer;
- float targetPosition = hoc.ToLocalSpace(screenSpacePosition).Y;
+ float targetPosition = hoc.ToLocalSpace(ToScreenSpace(position)).Y;
if (drawableRuleset.ScrollingInfo.Direction.Value == ScrollingDirection.Down)
{
@@ -103,10 +94,12 @@ namespace osu.Game.Rulesets.Mania.Edit
targetPosition = hoc.DrawHeight - targetPosition;
}
- return drawableRuleset.ScrollingInfo.Algorithm.TimeAt(targetPosition,
+ double targetTime = drawableRuleset.ScrollingInfo.Algorithm.TimeAt(targetPosition,
EditorClock.CurrentTime,
drawableRuleset.ScrollingInfo.TimeRange.Value,
hoc.DrawHeight);
+
+ return base.GetSnappedPosition(position, targetTime);
}
protected override DrawableRuleset CreateDrawableRuleset(Ruleset ruleset, IBeatmap beatmap, IReadOnlyList mods = null)