Thanks for the quick answer! So I would have to do different animations inside the sprite?
I am going to explain a little more of what I am trying to do (not very sucessfully). I am working on a small educative game, where I want to have a "tree of life" (a simplified phylogenetic cladogram of life forms).
In the end of the branch there will be a target, such as mammal, fish, fern, bird... and so on (I will have 22 classes).
I will have several images, positioned in the top left that should be then dragged and dropped to their right targets. To do this I am following the RPG Inventory Tutorial. There are some differences, I don't have a trash bin or a bag to put stuff. Also any image can be positioned in any target (unless it is already filled).
I also want to compare the id of the image with the target, to check if it has been correctly placed.
I tried to use one sprite as a array to keep all the images. What I tried to do was to, after placing one image, spawn another sprite in the next image (next frame). The problem with this is that I can't find a way to add a variable to a frame, or animation. So I could asssign the id to specific frames.
I had the idea to duplicate the sprites and there I could give them different IDs. Then I would have the same object, replicated 22 times, each one with a set of 3 frames all regarding the same image, so I could have all code done to only one sprite (if I have more than one different sprite I would have to do that for every sprite).
Maybe I could have an additional array where each position stores the ID value of each frame.
I am not sure of what about to do here. I was trying to do this with to sprites, but their behaviours are all messed up...