Here's a problem, which i have not solve yet, but I'm still trying
The task is: drag and drop actor. all the clones must move simultaneously and all the distances between clones could not be changed. We can drag anyone of clones - other move with him. We can add or remove clones.
I've tried two ways:
1. Change parent. On mouse_down event-Drag enable. Chosen clone must become parent for others, so other will move too. Does not work
2. I saw it somewhere here at the forum.
Actor named "zzz"
Global variable click, actor variables dX,dY
On clone's mouse down event
dX=xmouse-x+view.x;
dY=ymouse-y+view.y;
click=1;
on mouse up -
click=0;
On draw actor event
if(click == 1)
{ x = view.x + xmouse - dX;
y = view.y + ymouse - dY;
}
dX and dY are to store distance between each clone coordinates and mouse.
So, it does not work too. What is wrong?
Or, maybe somebody knows another solution?