audioxnaxna-4.0soundeffect

Difference between Play and Resume in XNA SoundEffects class


What is the difference between the Play and Resume methods in the XNA SoundEffects class? Both seem to start playing the sound at the current sound position. Can't I basically always use Play()?

I am using XNA 4 (with the latest updates).


Solution

  • The difference is simple:

    UPDATE

    If you're using SoundEffectInstance here's the answer to your question.

    Play method plays or resumes a SoundEffectInstance

    So the difference is that you can do both things only using Play, Resume of course can't be called if the sound effect is not paused.