mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 16:52:54 +08:00
Calculate position adjustment distance in local parent space
This commit is contained in:
parent
5bcb7c167c
commit
486be83177
@ -84,7 +84,7 @@ namespace osu.Game.Screens.Play.HUD
|
||||
|
||||
protected override bool OnMouseMove(MouseMoveEvent e)
|
||||
{
|
||||
positionalAdjust = Vector2.Distance(e.ScreenSpaceMousePosition, button.ScreenSpaceDrawQuad.Centre) / 200;
|
||||
positionalAdjust = Vector2.Distance(e.MousePosition, button.ToSpaceOfOtherDrawable(button.DrawRectangle.Centre, Parent)) / 200;
|
||||
return base.OnMouseMove(e);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user