27 lines
1.1 KiB
C#
27 lines
1.1 KiB
C#
using System;
|
|
using Cysharp.Threading.Tasks;
|
|
using UnityEngine;
|
|
|
|
namespace Code.Audio
|
|
{
|
|
public interface IAudioService
|
|
{
|
|
UniTask Initialize();
|
|
UniTaskVoid PlayRandomMusicUntilHumanityWillBeDestroyedForTheySins(MusicType musicType);
|
|
UniTaskVoid GladlyAskToStopMusic(MusicType musicType, AudioSnapshotState audioSnapshotState = AudioSnapshotState.None, float time = 1f, Action callback = null);
|
|
void StopMusic();
|
|
void GladlyAskToStopMusic(Action callback = null);
|
|
void TransitToSnapshot(AudioSnapshotState state, float time = 1f);
|
|
void PlaySFX(SFXSounds sfxId, Vector3 position);
|
|
void PlayEnemy(EnemiesSounds enemySoundId, Vector3 position);
|
|
|
|
delegate void OnAudioPlayingDelegate();
|
|
|
|
event OnAudioPlayingDelegate OnDispatcherStarted;
|
|
event OnAudioPlayingDelegate OnDispatcherEnded;
|
|
void PlayDispatcher(DispatcherSounds dispatcherSoundId);
|
|
void ChangeSetting(AudioType type, float value);
|
|
float GetSetting(AudioType type);
|
|
void PlayTestClip(AudioType audioType);
|
|
}
|
|
} |