mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 12:57:36 +08:00
Use common positional adjustment for note blueprints
This commit is contained in:
parent
0f755c814c
commit
fc0030a391
@ -49,7 +49,6 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
|
||||
base.Update();
|
||||
|
||||
Size = HitObject.DrawSize + new Vector2(0, HitObject.Tail.DrawHeight);
|
||||
Position = Parent.ToLocalSpace(HitObject.ScreenSpaceDrawQuad.TopLeft);
|
||||
|
||||
// This is a side-effect of not matching the hitobject's anchors/origins, which is kinda hard to do
|
||||
// When scrolling upwards our origin is already at the top of the head note (which is the intended location),
|
||||
|
@ -5,6 +5,7 @@ using osu.Framework.Graphics;
|
||||
using osu.Framework.Input.Events;
|
||||
using osu.Game.Rulesets.Edit;
|
||||
using osu.Game.Rulesets.Objects.Drawables;
|
||||
using OpenTK;
|
||||
|
||||
namespace osu.Game.Rulesets.Mania.Edit.Blueprints
|
||||
{
|
||||
@ -16,6 +17,13 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
|
||||
RelativeSizeAxes = Axes.None;
|
||||
}
|
||||
|
||||
protected override void Update()
|
||||
{
|
||||
base.Update();
|
||||
|
||||
Position = Parent.ToLocalSpace(HitObject.ToScreenSpace(Vector2.Zero));
|
||||
}
|
||||
|
||||
public override void AdjustPosition(DragEvent dragEvent)
|
||||
{
|
||||
}
|
||||
|
@ -32,7 +32,6 @@ namespace osu.Game.Rulesets.Mania.Edit.Blueprints
|
||||
base.Update();
|
||||
|
||||
Size = HitObject.DrawSize;
|
||||
Position = Parent.ToLocalSpace(HitObject.ScreenSpaceDrawQuad.TopLeft);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user