0
0

I can start the background music mp3 but I dont know how to stop it and start playing another mp3. Can any one help with this?

  • You must to post comments
0
0

When you call System::playSound(), you’ll want to pass in the address of a Channel pointer. Something like this:

[code:374v2mwt]Channel * pChannel;
pSystem->playSound(FMOD_CHANNEL_FREE, pSound, false, &pChannel);[/code:374v2mwt]

You can now execute operations on that Channel. If you want to stop playing that Channel, you can use Channel::stop():

[code:374v2mwt]pChannel->stop();[/code:374v2mwt]

Now you can do your System::playSound again with a different Sound to play a different file.

For further reference, see the documentation.

  • G
  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.