The tool is turned off by default. To turn it on, one simply has to look in the sprite pane, click the "i" by a sprite, then click the check box, as shown at left.
Sometimes, it is necessary to have a sprite that is only draggable sometimes or drags in a special way. Scripts can used to make a sprite draggable and are much more flexible than the Draggable Sprite feature. One script that can be used to make a sprite draggable is this:
when green flag clicked forever if <mouse down?> then if <touching [mouse-pointer v]?> then set [offset x v] to ((x position) - (mouse x)) set [offset y v] to ((y position) - (mouse y)) repeat until <not <mouse down?>> go to x: ((mouse x) + (offset x)) y: ((mouse y) + (offset y)) end end wait until <not <mouse down?>> end
Note that you need to create two variables: offset x and offset y.
The tool has many uses, the most popular of which are:
- Quicker project testing
- Reduced scripts (very useful in One Sprite One Script Projects)
- "Drag and drop" games
- Paint projects where a paintbrush, pen, or pencil is moved around
- Dress-up and makeup projects
- Customization projects, such as scene creators