mirror of
https://github.com/osukey/osukey.git
synced 2025-07-03 01:09:57 +09:00
Disallow selections to be moved outside of the playfield
This commit is contained in:
@ -367,7 +367,8 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
(Vector2 snappedPosition, double snappedTime) = composer.GetSnappedPosition(ToLocalSpace(movePosition), draggedObject.StartTime);
|
||||
|
||||
// Move the hitobjects
|
||||
selectionHandler.HandleMovement(new MoveSelectionEvent(movementBlueprint, startPosition, ToScreenSpace(snappedPosition)));
|
||||
if (!selectionHandler.HandleMovement(new MoveSelectionEvent(movementBlueprint, startPosition, ToScreenSpace(snappedPosition))))
|
||||
return true;
|
||||
|
||||
// Apply the start time at the newly snapped-to position
|
||||
double offset = snappedTime - draggedObject.StartTime;
|
||||
|
Reference in New Issue
Block a user