/// <summary> /// Adds a Player to this Voice Channel /// </summary> /// <param name="player"></param> public void AddPlayer(IPlayer player) { try { IVoiceChannel.AddPlayer(player); Players.Add(player); if (Settings.GetSettings().Debug) { Debug.LogColored($"Added player to Voice Channel: {Id} - Players: {Players.Count}"); } } catch (Exception e) { Debug.LogError(e.Message); Debug.LogError(e.StackTrace); } }
public void PlayerConnect(IPlayer client, string reason) { try { channel.AddPlayer(client); } catch (Exception ex) { Debug.CatchExceptions("OnPlayerConnect", ex); } }
public async Task OnPlayerConnectAsync(IPlayer player, string reason) => await AltAsync.Do(() => { GlobalVoice.AddPlayer(player); });