Hi all!
URL of experiment: https://run.pavlovia.org/MarinaIosifian/reverse-correlation-child-face/html
Description of the problem: My experiment runs properly in Builder. It crashes because the translation of the following code component is not correct, as I get “win is not defined” error. The code component is used to create a Continue button which will be enabled when my Form component is completed. How can I correct this code?
Begine routine:
continueButton = visual.ButtonStim(win, labelText= “Continue”, pos=(.35, -.4))
demo.aperture.disable()
in JavaScript:
continueButton = new visual.ButtonStim(win, {“labelText”: “Continue”, “pos”: [0.35, (- 0.4)]});
demo.aperture.disable();
Each frame:
continueButton.draw()
if demo.formComplete():
continueButton.buttonEnabled = True
if continueButton.buttonSelected:
continueRoutine = False
In Java:
continueButton.draw();
if (demo.formComplete()) {
continueButton.buttonEnabled = true;
}
if (continueButton.buttonSelected) {
continueRoutine = false;
}