//USER AUDIO COMPONENT HANDLING public void RegisterUserMusicComponent(UserMusicComponent uac) { Type uacType = uac.GetType(); if (UserMusicComponents.Find(x => x.GetType() == uacType) != null) { Debug.LogError($"Can't register UserMusicComponent of type {uacType} because an instance is already registered!"); throw new InvalidOperationException(); } UserMusicComponents.Add(uac); Debug.Log("Registered " + uac.GetType().Name); }
public string GetCurrentUserMusicComponent() { return(CurrentUserMusicComponent?.GetType().Name ?? null); }