I want the bones to move less than the amount they dragged.
For example, if I move my mouse while dragging by 50 px, to only move the dragged element by 25px.
`
function dragged(canvas_1, renderer, target, x, y){
if (target) {
x = spine.MathUtils.clamp(x, 0, canvas_1.clientWidth)
y = spine.MathUtils.clamp(y, 0, canvas_1.clientHeight);
renderer.camera.screenToWorld(coords.set(x, y, 0), canvas_1.clientWidth, canvas_1.clientHeight);
if (target.parent !== null) {
target.parent.worldToLocal(position.set(coords.x, coords.y));
target.x = position.x;
target.y = position.y;
} else {
target.x = coords.x;
target.y = coords.y;
}
}
}
`
(position.x * 0.5)
I wrote the code in this way, but it doesn't work properly. How can I make it work slower?