setDragLock(allowHorizontal, allowVertical)
Restricts this sprite to drag movement only on the given axis. Note: If both are set to false the sprite will never move!
Parameters
Name | Type | Argument | Default | Description |
---|---|---|---|---|
allowHorizontal | boolean | <optional> | true | To enable the sprite to be dragged horizontally set to true, otherwise false. |
allowVertical | boolean | <optional> | true | To enable the sprite to be dragged vertically set to true, otherwise false. |
- Source code: input/InputHandler.js (Line 1597)
Please login to continue.