Discuss Scratch

AlbertUmura
Scratcher
2 posts

How do I make a variable choose a sprite over the other?

so i have 2 variables that say the location(x,y) of a sprite clone but in the project i want to make i need more than one clone of the same sprite so i need it to make it choose one and not change constantly. how do i do that?
mstone326
Scratcher
1000+ posts

How do I make a variable choose a sprite over the other?

Make the x and y variables for this sprite only. Then every clone you get will create its own copy of that variable
medians
Scratcher
1000+ posts

How do I make a variable choose a sprite over the other?

mstone326 wrote:

Make the x and y variables for this sprite only. Then every clone you get will create its own copy of that variable
It also works with lists (when clicking Make a Variable/List in the Data category, you can click the “for this sprite only” option, but it only shows in sprites).
Also, I still believe that they should mention this fact somewhere, maybe a tutorial or if they bring back the Tips Window?
AlbertUmura
Scratcher
2 posts

How do I make a variable choose a sprite over the other?

Yea but how do I make another clone follow that clone after because I was using the variable to determine the place where that clone was so that the “bullet”
zedero
Scratcher
32 posts

How do I make a variable choose a sprite over the other?

That is not a full thought, but If you assign each clone a number in a list it can read the data of neighboring clones

Powered by DjangoBB