PDA

View Full Version : How2play a sound while music is playing?


eXPoser
2007-04-14, 18:43
hello,
I need help ^^
I want to play a sound when something happens in a script.
But this sound must not stop the music or video when its playing. :nod:

I think this( taken from the pythontutorial)
xbmc.Player().play(file)
will stop the music playing :shocked:
so.. how can I play a sound with python while playing music in xbmc?
thx4help

Nuka1195
2007-04-14, 19:54
xbmc.playSFX() will play a .wav file without interupting playback.

stanley87
2007-04-15, 03:39
oh sweet, cheers nuka, in my script, i need to play audio attachments over playback, but first, i will pause the xbmc player playback and playsfx, thanks!

eXPoser
2007-04-15, 12:52
Have a look in the sourcecode of pokertimer.
This stops the music and resumes in after playing the sound :nod: