| Reference | Downloads | Github

Movie plays AFTER routine end -> double condition needs to be bracketed

Hey all!

I am devising an experiment with some video presentations. As I will have 80 trials and two conditions, I put the video in two loops: one for the condition (let’s say cond1 and cond2) and one for repeating trials. Now, in the video routine, I have placed a text which shows ONLY under cond1, not under cond2. That works nicely.

However, then I conditioned the presentation of the video file like this: start(condition): $text.status==FINISHED or loopCond==“cond2”

In other words, the video plays immediately under cond2, no text needed. Under cond1, it plays after the text. It all works except for one issue. Under cond1, when the routine ends and a new one starts, the video’s audio plays again in the background once.

I don’t know at all why that is. If anyone has any idea, I would very much appreciate some help!

Thanks :slight_smile:

I added brackets to the video’s start textbox and now it works:

$(text_13.status==FINISHED or overtActivity==“none”)

It seems Psychopy translates it into code directly and the absence of brackets ruins it.

Hope this helps someone out there at some point :slight_smile: