Click once for audio playback

Hello.
I need to play audio using filestream when something happens, and I have do-seek on, I need to click do-seek button just once. When I try to do it, it keeps sending 1 endlessly, therefore audio file stays at 0 all the time. How can I replay audio file?

My logic is like:

if 1 is equal to 1 then send signal to do-seek and replay the audio. Hope you understood.
Thank you.

you are probably looking for the node TogEdge.
also make sure you know all these nodes:

tonfilm, thank you.
I tried TogEdge and it doesnt seem to work :C

can you show us your patch? either upload it or make a screenshot…

When the output of “equal” sign is true, i need to press seek-on just once

yes, use a TogEdge after the = and connect the Up Edge OR to combine the three… but its moire easy to use Change node in your case on the number directly.

I need to play different audio files depending on the language chosen, so I use TogEdge?
Thank you, sir in advance

for that you can use 3 FilesStreams and 3 AudioOut and connect each TogEdge to the Do Seek of the appropriate FileStream.
or use the WavePlayer, it can handle a spread of audio files and you can trigger each one individually. see its help patch…

okay, but i dont understand what should i put on down and up edge

you connect the UpEdge to the DoSeek…

Yes, it works, but only once. If the audio is played once it wont play again until i choose another button. Everything else is fine though

if you only get the number of the selected language but not the button click, then you don’t have the information of pressing the same button again. so what you need is the up edge of the buttons this would solve the problem directly.

well, it’s not a button it’s just a string that i get from another file

player.v4p (6.5 KB)

so you also need the event when the language change should happen, especially if its the same language as before…

player.v4p (6.7 KB)
(third edit)

hope it helps

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.