File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -103,8 +103,8 @@ export default class UIButtonDraggable extends UIButton {
103103 if ( ! this . _clip ) {
104104 return ;
105105 }
106- this . _startDragX = this . _clip . x ;
107- this . _startDragY = this . _clip . y ;
106+ this . _startDragX = this . _clip . x - gameObject . input . dragStartX ;
107+ this . _startDragY = this . _clip . y - gameObject . input . dragStartY ;
108108 }
109109
110110 /**
@@ -139,7 +139,7 @@ export default class UIButtonDraggable extends UIButton {
139139 _setupInteractive ( zone ) {
140140 super . _setupInteractive ( zone ) ;
141141 this . _dragZone = zone ;
142- zone . scene . input . dragDistanceThreshold = 3 ;
142+ // zone.scene.input.dragDistanceThreshold = 3;
143143 zone . scene . input . setDraggable ( zone , true ) ;
144144 zone . scene . input . on ( "dragstart" , this . _onDragStart , this ) ;
145145 zone . scene . input . on ( "drag" , this . _onDrag , this ) ;
You can’t perform that action at this time.
0 commit comments