So I’m confused, I want to try to make a picture matching game, but I don’t really understand how it works. I think the way to match each image is to give each image an ID, that way I think I can match them. Back to the beginning, how? I’m still confused about where to start, do I need to create a list to save the image and the ID at the same time? or what?
As with any game you must create your own internal logic to track things like this ID, and to map them to a particular image.
When a match of two particular images is made, look up the ID in your own structures and decide if it’s a match.
The ID could be an integer, a number, an enum, whatever you want to use. I recommend using a string so you can print it out with Debug.Log() as you’re going and make sure your code is working as expected and doesn’t have bugs.
If that doesn’t instantly give you the “ah ha!” moment, then work through at least two or three different tutorials out there for this extremely fundamental process. Not all of it will be text that can even be typed in this box.
This is also known as “memory game.”