I have a routine that is repeated 5 times using a loop. The routine ends when either the left or right button is clicked. I used this code in the every frame tab:
clicks = mouse.getPressed() if clicks or clicks: continueRoutine = False
At first, there is a feedback routine after this mouse routine and the previously clicked button is not dragged to the next trial. However when I remove that feedback routine a click in the first repetition will be dragged and take as answers in the following 4 repetitions.
How can I manually clear the pressed buttons? Or alternatively, how can I delay the start of the next trial until the mouse resets?