Description of the problem:
I am working on a child vocabulary test on Psychopy builder for behaviour study, the clickable objects worked perfectly offline, but when running on JS with local browser or pavlovia pilot, it gave no response to clicking, with logs show no click on clickable objects.
Do anyone know the cause of the problem? Thank you very much!
Vocab.psyexp (38.9 KB)
Your code component is set to Python only. Try Auto to generate JS code.
Hi wakecarter, thank you so much for your reply, I ran it with both auto translation to JS and manual JS re-write, but this leads to the following error when ran online after any click:
TypeError: Cannot read properties of undefined (reading ‘image_1’)
Try to run the experiment again. If the error persists, contact the experiment designer. log4javascript.js:148 FATAL 13:19:25.083 _GUI.dialog psychojs-2023.2.3.js:1200 | {}
BrowserConsoleAppender.append @ log4javascript.js:148
And in console:
Vocab.js:613 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading ‘image_1’)
at Vocab.js:613:60
at Array.forEach ()
at Scheduler._currentTask (Vocab.js:612:21)
at Scheduler._runNextTasks (Scheduler.js:226:24)
at Scheduler._runNextTasks (Scheduler.js:233:37)
at Scheduler._runNextTasks (Scheduler.js:233:37)
at update (Scheduler.js:140:29)
Also it does not have any problem when ran offline.