How to know the distance of the Drag, unused PositionUP or onInputUp to differentiate a drag from a long click?
it is a some code:
var fnd = game.add.group();
var o = fnd.create(game.world.randomX, game.world.randomY, 'fon');
o.events.onDragStart.add(this.DragActivo, this);
DragActive = function (image) {
//When something has been moved is drag but when something has been pressed for long time is clicked
};
You can use the property sprite.input.dragDistanceThreshold = 3;
in order to start dragging only if the pointer moves a minimum amount of pixels when after onInputDown
.