psychopy.org | Reference | Downloads | Github

Trial advancing only when the correct key is pressed

If this template helps then use it. If not then just delete and start from scratch.

OS: WIN 10 x64
PsychoPy version: 1.85.4:
Standard Standalone? (y/n): Y
What are you trying to achieve?:
I am trying to run a simple Posner task that consists in presenting a fixation cross, followed by a word (left or right on the screen), followed by a target cue (left or right on the screen). The user has to press the ‘left’ or ‘right’ keys, depending on where the probe appeares. There are multiple trials. I want for the program to advance from one trial to another only if the correct key is pressed
What did you try to make it work?:
My task runs perfectly. I also have a correctAns column in my excel file. The only problem is that i want to advance from one trial to another only if the correct key is pressed. So for example if the target cue appeares on the left of the screen and the user presses the ‘right’ key, the program should not advance to the next trial until the ‘right’ key is pressed.