Hi everyone.<br> I have found very funny to study JS through writing simple games. Here I write one http://codepen.io/Kuzyo/pen/Datoc , but have some bugs, maybe someone can help me.
Here is rules – There are 20 squares that conceal 10 pairs of characters. You just select two squares. If the two you select match then they will remain visible, if they don’t then they will disappear again after a second or so. The counter counts how long it takes you to match all of the pairs, after finishing you click stop button. <br>
I can’t solve : 1) how to make that player can click only two times (even if he want he cant click third time ),; 2) In script I compare innerHTML of cards, sometimes even if they match they dissapear, but if you click again on this cards they stay visible how I planed. Thanks.
Hi guys.<br> I understand that going through someone’s code is very difficult. I only ask somebody to look in my code and give some advices in best practices( about organization and so on…). Thanks in advance http://codepen.io/Kuzyo/pen/Datoc
Viewing 2 posts - 1 through 2 (of 2 total)