Any advice on creating a way for clones to identify themselves? I noticed that clones cant have their own variables even with the Create Variables library, my project has clones be able to target a different sprite based on an aggro chance rng and I need a way for them to be able to maintain this for multiple turns. My initial thought was that each clone could have an individual variable but there'd be no way for the code to check the clone# that I know of.
Any help would be appreciated
I've used the name of the cloned sprite in the past to hold info
could you show me an example of this?
Ok but wouldnt "my name" get overridden when a new clone is produced?
When a new clone is created - it has no name
I mean when your script says "set my name to pick random 1 to 100", thats a variable, but the variable would get overridden when the next clone is created during that script, meaning all clones names would be the same, no?
No - they are unique to each clone
oh alright, got it figured out, didn't see the "my" part of set, thank you for the help
Sprite local variables also are unique in every clone. I use that, because I feel like sprite local variable are more reliable.
Oh, and if you want a truly unique id, you need to check all the clones ids to see if you're creating a new clone with an id that is the same as another one.
yeh I have a variable decide the name that increases each time a clone is made xD so unique identifiers each time
That's a good way to do it.
well ,there is a when I start as clone block but I don't think you can identify a clone, tell me if I'm wrong
that is the block I'm talking about.
you can also keep a reference to many clones in a list like this:
Or you can use the my [clones] reporter.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.