Coding Issue- Is there a way to do a matching game and to reset the clicks to where the other matching pairs aren't affected?

I am in the process of creating a Cospace and I am having technical issues. I am attempting to create a scene that is interactive through clicks and the students will be able to match pairs. But when a correct match is paired and the next match is attempted to be paired, it shows up as an incorrect pair due to the fact that the initial pair was already clicked. The way I’ve coded it, when a person is clicked, they move up a few meters and when the person’s pair moves up, they’re deleted. When the pair is wrong it shows the text that the pair is incorrect. But, again, when the next pair is attempted to be matched, after the correct match is paired, it automatically states that the pair is incorrect when the first person of the next pair is clicked. This is due to the fact that the persons of the other pair were already clicked and does not match with the next person being clicked. How should I code it to fix this problem?

If I understood your issue, you need to create variables to store the state of clicking on a person then erase it when it’s incorrect.
Otherwise, feel free to share a remixable space of your code in order to have more insights on your issue.


1 Like

This is the share link: CoSpaces Edu :: DNA Matching Game . I am still having issues. Ultimately, I would like to have the CoSpace to where the student is free to start by clicking whichever individual they desire to start with and this CoSpace run smoothly regardless of what is clicked.

Hi, here a fix of your issue:
Adjustment DNA Matching Game

Let me know if there is something wrong.
Good Luck.

1 Like

Very helpful! Thank you so much!