1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 11:37:28 +08:00

Transform screen mouse coordinates to local space coordinates.

This commit is contained in:
ProgrammaticNajel 2019-01-26 18:19:01 +08:00
parent 718136a892
commit e939f75f4b

View File

@ -22,8 +22,8 @@ namespace osu.Game.Rulesets.Osu.Edit.Blueprints.HitCircles
{
base.LoadComplete();
// Fixes a 1-frame position discrpancy due to the first mouse move event happening in the next frame
HitObject.Position = GetContainingInputManager().CurrentState.Mouse.Position;
// Fixes a 1-frame position discrepancy due to the first mouse move event happening in the next frame
HitObject.Position = Parent.ToLocalSpace(GetContainingInputManager().CurrentState.Mouse.Position);
}
protected override bool OnClick(ClickEvent e)