Continuing the discussion from Can't break out of loops using a variable in Pavlovia:
URL of experiment: Pavlovia
Description of the problem: Below is a screenshot of my flow. nReps for the EffortLoop is set to a variable I created that is updated (EffortRepN = EffortRepN + 5) in a code component in the Choice routine (occuring before the EffortLoop), and the EffortLoop repetitions function as they should.
For the TrialsLoop, I have set nReps to variable TrialsRepN, which is conditionally updated (TrialsRepN = TrialsRepN + 1) in a code component in the Choice routine (occuring within the TrialsLoop), and the TrialsLoop ends after 1 repetition (TrialsRepN is set to 1 in a beginning of experiment code component), so it appears the TrialsRepN value is not being updated (although other aspects of the conditional code it is nested within are working). Is it possible to update the value of an nReps variable within the loop that references it?
I have not used the $ for the nReps variables. Much appreciation for any suggestions.