Hi Erikvdb!
First of all thank you so much for the prompt and detailed help! It really helps me understand what is happening in the code. Before I saw your reply, I eventually had managed to do this, it sort of seemed to work:
import viz
import viztask
import random
viz.go()
sound = viz.addAudio('pip.wav')
def soundloop():
for x in range (10):
yield viztask.waitTime(random.randrange(3,7,1))
pip.play()
soundtask = viztask.schedule(soundloop())
But I can understand how your code if different and better and I will play around with it a bit to see what happens if I change various bits of it.
Again, thank you so very much!