Hi
I have a problem when it comes to if sentences.
game works so that a buzzer will make a sound and when the sound is finished, there are two buttons (indicating each player). first person to press will get a point.
as you can see in the code, there will be a score on a lcd screen.
My problem:
if a player presses when the sound beep, he will be punished by minus point. I've tried with another if sentences and put the state at a higher value, but the problem is that it then skips one the "if sentences" so it only gets registered minus points.
Appendix 1 only positive score
Appendix 2 with minus points, but the score only goes towards minus.
anyone have a suggestion on how I can solve the problem?
opgave_1A_B_D_innlevering.ino (2.2 KB)
only_minus_points_.ino (2.44 KB)