Discuss Scratch
- Discussion Forums
- » Help with Scripts
- » How do I detect if a clone is touching a clone of itself
- Gamdapiko24
-
86 posts
How do I detect if a clone is touching a clone of itself
I am making a game and it has a bunch of clones of enemies and I want them to die if they are touching each other. But I don't know how to detect if a clone is touching another clone of itself. This applies to all clones in the sprite “enemy”.
This is the game if you need it:
https://scratch.mit.edu/projects/1121874608
Thank you,
Gamdapiko
This is the game if you need it:
https://scratch.mit.edu/projects/1121874608
Thank you,
Gamdapiko
- paster_master100
-
100+ posts
How do I detect if a clone is touching a clone of itself
<touching [Myself v] ?>(the “Myself” has to be the dropdown from the
create clone of [myself v]block
- Gamdapiko24
-
86 posts
How do I detect if a clone is touching a clone of itself
There is no “Myself” on the drop-down.
- paster_master100
-
100+ posts
How do I detect if a clone is touching a clone of itself
use a separated clone drop down menu to make it! There is no “Myself” on the drop-down.
- Gamdapiko24
-
86 posts
How do I detect if a clone is touching a clone of itself
I am confused.
- Gamdapiko24
-
86 posts
How do I detect if a clone is touching a clone of itself
THESE ARE TOO MANY BLOCKS
- paster_master100
-
100+ posts
How do I detect if a clone is touching a clone of itself
use the cleanup function and it should be at the top (at least what I think) THESE ARE TOO MANY BLOCKS
- shenmuueedoesnumbers
-
77 posts
How do I detect if a clone is touching a clone of itself
how did you get so many secret blocks
- shenmuueedoesnumbers
-
77 posts
How do I detect if a clone is touching a clone of itself
and why are all of the blocks broken
- paster_master100
-
100+ posts
How do I detect if a clone is touching a clone of itself
I SWEAR the (myself v) block worked I tested it in my game and it worked and why are all of the blocks broken
- 10goto10
-
1000+ posts
How do I detect if a clone is touching a clone of itself
You can use a join block inside of a touching block to see if a sprite or a clone of that sprite is touching one if its clones.
So, if a sprite is named “Sprite1” then this
will let you tell when it or its clones is touching another of its clones. That second field has to be nothing, not a space.
So, if a sprite is named “Sprite1” then this
<touching (join [Sprite1] []) ?>
will let you tell when it or its clones is touching another of its clones. That second field has to be nothing, not a space.
- Koamodo975
-
1000+ posts
How do I detect if a clone is touching a clone of itself
There is another way. Go into a different sprite and get an if touching block for the sprite, then drag it into the first sprite. You can use a join block inside of a touching block to see if a sprite or a clone of that sprite is touching one if its clones.
So, if a sprite is named “Sprite1” then this<touching (join [Sprite1] []) ?>
will let you tell when it or its clones is touching another of its clones. That second field has to be nothing, not a space.
- Tornadowrath
-
66 posts
How do I detect if a clone is touching a clone of itself
k this is actually pretty easy with a bug, just go into another sprite in the editor, and pull a
block into the original sprite and detect for touching that
<touching [ the original sprite] ?>
block into the original sprite and detect for touching that
- Discussion Forums
- » Help with Scripts
-
» How do I detect if a clone is touching a clone of itself