chip-game/Assets/Scripts/CoinSound.cs
2026-01-12 09:36:17 +03:00

17 lines
492 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class CoinSound : MonoBehaviour
{
private void OnEnable()
{
AudioSource source = GetComponent<AudioSource>();
//source.volume = float.Parse(SettingsManager.instance.GetSettingValue("Громкость эффектов")) / 10;
source.volume = SettingsManager.GetFloat("SoundsVolume", 0.5f);
source.Play();
//Destroy(source, source.clip.length);
}
}