Discuss Scratch

tapuzio
Teacher
12 posts

How to prevent Mouse dragging of sprites?

My browser / operating system: MacOS Macintosh X 10.14.6, Chrome 79.0.3945.130, No Flash version detected

Is there a way to prevent users from dragging sprites in a project?

There's a “set draggable” block but it doesn't prevent anything.

I made a fruit slicer game, so the player is clicking and dragging to slice the fruit, but if you happen to begin clicking and dragging ON the fruit, you'll move the clone around instead of slicing. Also if you lose you can drag the “game over” sprite before you realize you need to stop slicing fruit.
DarkCrystal42
Scratcher
100+ posts

How to prevent Mouse dragging of sprites?

By default, users which are not you should not be to drag sprites like this. If you haven’t shared the project yet, when you play you have the power to drag the sprites. Other users should not have that power. Hope this helps!
minor-edit
Scratcher
500+ posts

How to prevent Mouse dragging of sprites?

It's a feature of Scratch that if you are in the project editor and not in full screen mode then sprites are always draggable. There is no way to turn it off, but maybe someday a menu will be added to toggle it.
tapuzio
Teacher
12 posts

How to prevent Mouse dragging of sprites?

thanks for the response. I never test the game full screen so I had no clue I had to do that to prevent dragging. It's fixed using your advice…

here's the game:
https://scratch.mit.edu/projects/364260948/

Powered by DjangoBB