Hi,
I want an image to appear on the screen 500 ms after a mouse press. The solution I have right now is very unreliable (i.e. the image doesn’t always show) and I suspect it has to do with the timer, but I don’t understand why.
What I have right now is this:
timer = core.Clock()
in my code component in tab Begin Routine:
startdelay = False
waitforit = True
Each Frame
if startdelay:
while timer.getTime() < 0.5:
waitforit = True
if timer.getTime() > 0.5:
waitforit = False # image component starts when waitforit is False
break
elif vtreplay.isPressedIn(rpVT):
startdelay = True
timer.reset()
What am I missing?
-Sabine