Answered
increase drop area
Hi!
I want to increase a dropzone success detection area from html5 code.
Teh working code is here:
root.check = function()
{
var spot = slots.getObjectUnderPoint(pieces.target.x, pieces.target.y);
if (!spot)
{
root.onMiss();
return;
}
root.slot = spot.parent;
if (root.slot)
{
if (pieces.target.name === root.slot.name)
{
root.onMatch();
if (pieces.count === pieces.children.length)
root.onWin();
}
else
root.onMiss();
root.slot = null;
}
else
root.onMiss();
};
How can i extend the sucess area, so that you don't have to throw it exactly right to succeed?
Thanx!
