I was about to give up and find some other way.
I tried to follow the way you told me, like this
. in the first inline code(inline 9 in the picture) = totalreward = 0
and the second inline code(inline 2 in the picture) =If StimSlide.ACC = 1
Thentotalreward = totalreward + 125 End If (the amount of money they can get is 125. So I wrote like this. Is this right ?)
and the last inline code(inline 8 in the picture) = c.SetAttrib
"totalreward", totalreward
And I added a text in the feedback display slide, and wrote You earned [totalreward]
rewards!
And It worked out..partly..
When I run the file..feedback slide shows that "You earned 0 rewards!" at every trial.
What is wrong?
I want to show the participants how much money they won at every trial.
And also, I want to substract the same amount of money every time participant lost a trial.
I added like this: If StimSlide.ACC = 0 Thentotalreward = totalreward - 125 in the inlinecode 2. But when I did this, error message popped up.
I would be very, very grateful if you give me some advice. Thank you so much!