When i have a sprite with the behaviors "Drag and Drop", I want to drag, and only drop the object in a specific space, later, the object is fixed in space . It's possible?
Develop games in your browser. Powerful, performant & highly capable.
Check out this tutorial.
https://www.scirra.com/tutorials/5347/t ... r-tutorial
I believe the first example capx file is what you're looking for.
The easiest way is
make an small invisible sprite object where your dragedSprite should land
create an instance variable for dragedSprite like "IsDropped = 0"
now to the events
On mouse realese - If dragedSprite overlaps invSprite then move dragedSprite to invSprite and set "IsDropped = 1"
And make a rule where you only can drag objects with instance variable "IsDropped = 0
here is a capx from a tutorial (free book) with I think the same logic
https://www.dropbox.com/s/6kiwvhoa00jdn ... .capx?dl=0
or download the book to learn more about it https://www.scirra.com/blog/172/level-z ... uct-2-book