Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » While dragging sprites, cannot detect touching other objects/sprites?
- blahblahblacksheepp
-
New Scratcher
3 posts
While dragging sprites, cannot detect touching other objects/sprites?
Hi,
As said in title, if i drag a sprite (sprite1 in the link example below) and want to alert a say function when it touches another object/sprite (an apple in the link example), it doesn't work? It will alert when I drag it to the apple and only when I release it at the apple.
https://scratch.mit.edu/projects/353917132
Any help will be appreciated!
As said in title, if i drag a sprite (sprite1 in the link example below) and want to alert a say function when it touches another object/sprite (an apple in the link example), it doesn't work? It will alert when I drag it to the apple and only when I release it at the apple.
https://scratch.mit.edu/projects/353917132
Any help will be appreciated!
Last edited by blahblahblacksheepp (Dec. 14, 2019 18:18:07)
- Mast3rGenius
-
Scratcher
100+ posts
While dragging sprites, cannot detect touching other objects/sprites?
When using the draggable feature, it's like lifting the sprite above the project, so you'll need to either make a second sprite that follows the exact location of the apple or make your own dragging system (I suggest method one)
- blahblahblacksheepp
-
New Scratcher
3 posts
While dragging sprites, cannot detect touching other objects/sprites?
When using the draggable feature, it's like lifting the sprite above the project, so you'll need to either make a second sprite that follows the exact location of the apple or make your own dragging system (I suggest method one)
I'm trying to make a falling objects game where the player navigates their character via dragging their mouse, so method 1 doesn't seem feasible. Can you teach me another method?
- deck26
-
Scratcher
1000+ posts
While dragging sprites, cannot detect touching other objects/sprites?
Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.
- blahblahblacksheepp
-
New Scratcher
3 posts
While dragging sprites, cannot detect touching other objects/sprites?
Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.
Just realise you need to be on project page then it'll work. It still have some lag in between but oh wells.
Thank you all!
- SOyBOi1234
-
Scratcher
14 posts
While dragging sprites, cannot detect touching other objects/sprites?
Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.repeat until what?
- deck26
-
Scratcher
1000+ posts
While dragging sprites, cannot detect touching other objects/sprites?
What it says!Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.repeat until what?
- SOyBOi1234
-
Scratcher
14 posts
While dragging sprites, cannot detect touching other objects/sprites?
What it says!Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.repeat until what?
when this sprite clicked
repeat until <not <mouse down?>>
go to (mouse pointer v)
end
Last edited by SOyBOi1234 (Nov. 11, 2020 01:57:03)
- champion_ofcloud-var
-
Scratcher
500+ posts
While dragging sprites, cannot detect touching other objects/sprites?
Essentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
- champion_ofcloud-var
-
Scratcher
500+ posts
While dragging sprites, cannot detect touching other objects/sprites?
for my mc potion thingyEssentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
for scratch
with mr game and watch
- champion_ofcloud-var
-
Scratcher
500+ posts
While dragging sprites, cannot detect touching other objects/sprites?
for scratchfor my mc potion thingyEssentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
with mr game and watch
Last edited by champion_ofcloud-var (April 20, 2021 00:31:38)
- champion_ofcloud-var
-
Scratcher
500+ posts
While dragging sprites, cannot detect touching other objects/sprites?
with mr game and watchfor scratchfor my mc potion thingyEssentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
- champion_ofcloud-var
-
Scratcher
500+ posts
While dragging sprites, cannot detect touching other objects/sprites?
nvmwith mr game and watchfor scratchfor my mc potion thingyEssentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
- Yoosle
-
Scratcher
82 posts
While dragging sprites, cannot detect touching other objects/sprites?
nvmwith mr game and watchfor scratchfor my mc potion thingyEssentially when this sprite clicked, repeat until not mouse down, go to mouse pointer, end of repeat.yea but what if clone
nobody has posted on this in like 6 months why didnt u just create a new thread
- Discussion Forums
- » Help with Scripts
-
» While dragging sprites, cannot detect touching other objects/sprites?





