//public Vector2 _3DMinMaxDistance
        //{
        //    get { return minMaxDistance; }
        //    set { minMaxDistance = value; if (SoundGlue != null) SoundGlue._3DMinMaxDistance = new Vector2(value.X, value.Y); }
        //}
        //private Vector2 minMaxDistance;
        private SoundChannel PlayAnySound(PlayArgs args)
        {
            IChannelGlue channelGlue = SoundManager.Instance.SystemGlue.PlaySound(SoundGlue, true, args.Looping);

            var soundChannel = new SoundChannel(this, channelGlue) { Paused = true, WantsToPlaySound = SoundGlue, WantsToPlaySoundArgs = args };     // TODO: add args stuff

            if (Is3DSound)
            {
                soundChannel._3DPanLevel = SoundManager.Instance._3DPanLevel;
                //soundChannel._3DSpread = SoundManager.Instance._3DSpread;
            }
            return soundChannel;
        }
 private void FinalShutdown()
 {
     SoundChannel = null;
     SoundManager.Instance.DeregisterChannel(this);
     if (PlaybackStopped != null)
         PlaybackStopped(this, null);
 }
 //public float _3DSpread
 //{
 //    get { return spread; }
 //    set { spread = value; if (Active) SoundChannel._3DSpread = value; }
 //}
 //private float spread;
 private void soundChannel_PlaybackStopped(object sender, EventArgs e)
 {
     SoundChannel = null;
     if (!shuttingDown)
         QueuePlayback((float)(random.NextDouble() * (MaxWaitTime - MinWaitTime) + MinWaitTime));
     else
         FinalShutdown();
 }
 //////////////////////////////////////////////////////////////////////////////////////////
 // Interval part /////////////////////////////////////////////////////////////////////////
 //////////////////////////////////////////////////////////////////////////////////////////
 public void Play(PlayArgs args)
 {
     waiting = false;
     if (Is3DSound)
     {
         //Vector3 pos = GetPosition();
         //Vector3 vel = GetVelocity();
         //SoundChannel = (SoundChannel)Playable.Play(pos, vel);
         SoundChannel = (SoundChannel)Playable.Play(args);
     }
     else
     {
         if (fadingIn)
             fadingIn = false;       // reset so the remaining sounds won't fade in
         else
             args.FadeInTime = 0;
         SoundChannel = (SoundChannel)Playable.Play(args);
     }
 }