コード例 #1
0
        protected void SetGain(float gain)
        {
            if (EngineConfig.SoundSystem == FreeSL.FSL_SOUND_SYSTEM.FSL_SS_NOSYSTEM)
            {
                return;
            }
            //LogManager.Singleton.LogMessage(LogMessageLevel.LML_CRITICAL, "SETTING GAIN: " + this.Name + " Base: " + this.GetBaseGain() + ", final gain:" + gain);

            FreeSL.fslSoundSetGain(_sound, gain);
        }
コード例 #2
0
 public void RemoveSound()
 {
     if (_withSound)
     {
         try{
             Console.WriteLine("Destroying: " + this._soundFile);
             FreeSL.fslSoundSetGain(_sound, 0.1f);
             FreeSL.fslFreeSound(_sound, true);
             _withSound = false;
         }
         catch (Exception ex) {
             LogManager.Singleton.LogMessage(LogMessageLevel.LML_CRITICAL, "Exception while trying to remove sound: " + _soundFile + " (" + ex.Message + ") " + ex.StackTrace);
         }
     }
 }
コード例 #3
0
 public void SetGain(float gain)
 {
     FreeSL.fslSoundSetGain(_sound, gain);
 }