Draggable Objects (Transparancy)


I have some draggable sprite objects. They are PNGs with transparent areas. I want the draggable behavior to ignore the transparant areas, ie, only drag the visible parts of the object.

Does anyone know how to do it?

Thanks in advance!

You cannot. Draggable, just like the “Mouse is on” event conditions, only cares about the actual object boundaries.

They do not see/care about transparency or collision masks.

Are there any workarounds?

You can use a placeholder sprite smaller than the others add the draggable behavior to that placeholder then set the position of the others spites to the placeholder if this is dragging, maybe use Link or add an object variable to check if this sprite.Variable(number) == placeholder.variable(number) then set this sprite position to placeholder.

This is a good idea, I might just do that. Thank you!

n/m, I didn’t read the question thoroughly enough.