Ejemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     cardDelay.value     = SettingsUtil.GetCardDelay() * 4;
     musicVolume.value   = SettingsUtil.GetMusicVolume();
     sfxVolume.value     = SettingsUtil.GetSFXVolume();
     penalties.isOn      = SettingsUtil.IsPenaltiesAllowed();
     negativeScores.isOn = SettingsUtil.IsNegativeScoresAllowed();
 }
Ejemplo n.º 2
0
 public static void PlaySFX(AudioSource audioSource, AudioClip audioClip, bool forcePlay = true)
 {
     if (audioSource == null || audioClip == null)
     {
         return;
     }
     audioSource.volume = SettingsUtil.GetSFXVolume() / 100;
     audioSource.loop   = false;
     PlayAudio(audioSource, audioClip, forcePlay);
 }