Creating a Tile Game Like Memory

Every tutorial I’ve found so far includes a controlled character, if I just want the user to interact with my 2D environment in a way similar to the memory card game, where should I start?

So basically there’s 150 cards total and there has to be a certain amount of “pairs” that show up per level. I want users to be able to "flip’ the cards and match them. When a match is correct they get points and the cards are removed. When a match is incorrect they lose health. I’ve seen how the UI elements work from the other tutorials but I’m just kind of at a loss for how to make a “click” based game. I understand how to get colliders to work with other objects but there’s only the collision object and I want it to be an “on click” reaction. Is there a script I should be using?

Can someone help direct me better? It’d be really appreciated.

Try this: [4.6 - UI] Calling function on button click via script - Questions & Answers - Unity Discussions

Basically, you’ll add click handlers (through the editor or through scripts) which then instruct the card to flip. Then the card should flip back after a timed event or when clicked again. The question in the link above is regarding a button, but should work with invisible (alpha value of 0) UI fields (hit boxes over your cards) as well.

1 Like

Thank you catfang! This helps a lot.