Commit 2016d33 1 parent cab9a1c commit 2016d33 Copy full SHA for 2016d33
File tree 1 file changed +8
-1
lines changed
osu.Game/Screens/Edit/Compose/Components
1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -53,9 +53,16 @@ protected override void CreateContent()
53
53
float maxDistance = new Vector2 ( dx , dy ) . Length ;
54
54
int requiredCircles = Math . Min ( MaxIntervals , ( int ) ( maxDistance / DistanceBetweenTicks ) ) ;
55
55
56
+ // We need to offset the drawn lines to the next valid snap for the currently selected divisor.
57
+ //
58
+ // Picture the scenario where the user has just placed an object on a 1/2 snap, then changes to
59
+ // 1/3 snap and expects to be able to place the next object on a valid 1/3 snap, regardless of the
60
+ // fact that the 1/2 snap reference object is not valid for 1/3 snapping.
61
+ float offset = SnapProvider . FindSnappedDistance ( ReferenceObject , 0 ) ;
62
+
56
63
for ( int i = 0 ; i < requiredCircles ; i ++ )
57
64
{
58
- float diameter = ( i + 1 ) * DistanceBetweenTicks * 2 ;
65
+ float diameter = ( offset + ( i + 1 ) * DistanceBetweenTicks ) * 2 ;
59
66
60
67
AddInternal ( new Ring ( ReferenceObject , GetColourForIndexFromPlacement ( i ) )
61
68
{
You can’t perform that action at this time.
0 commit comments